{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:36.957090Z",
     "start_time": "2018-10-15T13:46:36.278580Z"
    },
    "collapsed": true,
    "hide_input": false
   },
   "outputs": [],
   "source": [
    "import torch\n",
    "import torch.nn as nn\n",
    "import torch.nn.functional as F\n",
    "from torch.autograd import Variable\n",
    "from torch.optim.lr_scheduler import StepLR\n",
    "from torch.utils.data import DataLoader,TensorDataset\n",
    "import torch.utils.data as data\n",
    "import numpy as np\n",
    "import scipy.io as sio\n",
    "import math\n",
    "import argparse\n",
    "import random\n",
    "import os\n",
    "from My_Loss import HardTripletLoss\n",
    "from My_Loss import HardTripletLoss2\n",
    "from My_Loss import HardTripletLoss_D\n",
    "from tensorboardX import SummaryWriter\n",
    "import visdom"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:36.963709Z",
     "start_time": "2018-10-15T13:46:36.958157Z"
    },
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "BATCH_SIZE = 64\n",
    "EPISODE = 100000\n",
    "TEST_EPISODE = 1000\n",
    "LEARNING_RATE =1e-5\n",
    "Weight_Deacy = 0\n",
    "GPU = 0\n",
    "Margin = 3"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:39.069621Z",
     "start_time": "2018-10-15T13:46:36.965421Z"
    },
    "hide_input": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "init dataset\n",
      "----------------------------------------------------------------------------------------------------\n"
     ]
    }
   ],
   "source": [
    "print(\"init dataset\")\n",
    "##################################参数##################################################################\n",
    "dataroot = '../data'\n",
    "dataset = 'AwA1_data'\n",
    "image_embedding = 'res101'               #ResNet101层\n",
    "class_embedding = 'original_att'         #属性表达 85-d\n",
    "#######################################读取视觉特征###################################################################\n",
    "\n",
    "matcontent = sio.loadmat(dataroot + \"/\" + dataset + \"/\" + image_embedding + \".mat\")  #scipy loadmat\n",
    " \n",
    "feature = matcontent['features'].T         #转置 30478x2048 每一行是一个完整的样本\n",
    "\n",
    "label = matcontent['labels'].astype(int).squeeze() - 1   #matlab begin 1 ,numpy begin 0\n",
    "########################################读取属性特征###########################################################\n",
    "\n",
    "matcontent = sio.loadmat(dataroot + \"/\" + dataset + \"/\" + class_embedding + \"_splits.mat\")\n",
    "\n",
    "    \n",
    "# numpy array index starts from 0, matlab starts from 1\n",
    "trainval_loc = matcontent['trainval_loc'].squeeze() - 1    #squeeze()去掉维度中的1 AxBx1 --->AxB\n",
    "\n",
    "test_seen_loc = matcontent['test_seen_loc'].squeeze() - 1\n",
    "test_unseen_loc = matcontent['test_unseen_loc'].squeeze() - 1\n",
    "\n",
    "attribute = matcontent['att'].T    #转置 50x85 每行是整个属性向量\n",
    "\n",
    "x = feature[trainval_loc]                      # train_features trainval里面是图片的编号 begin with 0 ，19832个\n",
    "train_label = label[trainval_loc].astype(int)  # train_label  int类型没变 每个图片的lable 19832个\n",
    "train_id = np.unique(train_label)\n",
    "\n",
    "att = attribute[train_label]                   # train attributes 每个图片的属性 19832个\n",
    "\n",
    "    \n",
    "x_test = feature[test_unseen_loc]                   # test_feature 5685个\n",
    "test_label = label[test_unseen_loc].astype(int)     # test_label   5685个\n",
    "\n",
    "x_test_seen = feature[test_seen_loc]                #test_seen_feature 4958个\n",
    "test_label_seen = label[test_seen_loc].astype(int)  # test_seen_label  4958个\n",
    "    \n",
    "test_id = np.unique(test_label)                     # test_id  10个类 ，unique去重\n",
    "att_pro = attribute[test_id]                        # test_attribute 每一类的属性向量 10x85\n",
    "\n",
    "# train set\n",
    "train_features = torch.from_numpy(x)   #np-->tensor\n",
    "#train_fearures_negative = torch.from_numpy(x_negative)\n",
    "\n",
    "sample_attributes=[]\n",
    "train_label = torch.from_numpy(train_label).unsqueeze(1) #每张图片的属性转化 ，unsqueeze(1)就是插入到第一维度 AxB维-->Ax1xB\n",
    "# attributes\n",
    "all_attributes = np.array(attribute)  #所有50类属性转变为numpy数组???属性向量仍然用的numpy类型 没有转化为pytorch\n",
    "    \n",
    "#print('-'*50)\n",
    "attributes = torch.from_numpy(attribute) \n",
    "#print(attribute)\n",
    "# test set\n",
    "\n",
    "test_features = torch.from_numpy(x_test)\n",
    "#print(test_features.shape)\n",
    "\n",
    "test_label = torch.from_numpy(test_label).unsqueeze(1)\n",
    "#print(test_label.shape)\n",
    "\n",
    "testclasses_id = np.array(test_id)\n",
    "#print(testclasses_id.shape)\n",
    "\n",
    "test_attributes = torch.from_numpy(att_pro).float()\n",
    "#print(test_attributes.shape)\n",
    "\n",
    "test_seen_features = torch.from_numpy(x_test_seen)\n",
    "#print(test_seen_features.shape)\n",
    "\n",
    "test_seen_label = torch.from_numpy(test_label_seen)\n",
    "\n",
    "train_data = TensorDataset( train_label, train_features )\n",
    "#train_data = TensorDataset(train_label, train_features, train_fearures_negative)\n",
    "\n",
    "#################here need new code to make triplet data#####################\n",
    "print('-'*100)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:39.073005Z",
     "start_time": "2018-10-15T13:46:39.070756Z"
    },
    "collapsed": true,
    "hide_input": true
   },
   "outputs": [],
   "source": [
    "from my_net_3 import AttributeNetwork\n",
    "from my_net_3 import MetricNetwork"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:41.699509Z",
     "start_time": "2018-10-15T13:46:39.074317Z"
    },
    "hide_input": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "init networks\n",
      "----------------------------------------------------------------------------------------------------\n"
     ]
    }
   ],
   "source": [
    "# init network\n",
    "print(\"init networks\")\n",
    "attribute_network = AttributeNetwork(85,1024,2048)  #85d属性 1024隐藏层 2048输出 85d到2048d\n",
    "metric_network = MetricNetwork(2048,1024,2048)\n",
    "\n",
    "attribute_network.cuda(GPU) \n",
    "metric_network.cuda(GPU)\n",
    "\n",
    "#学习率每200k步 乘0.5\n",
    "attribute_network_optim = torch.optim.Adam(attribute_network.parameters(), lr=LEARNING_RATE,weight_decay=Weight_Deacy)\n",
    "metric_network_optim = torch.optim.Adam(metric_network.parameters(), lr=LEARNING_RATE,weight_decay=Weight_Deacy)\n",
    "#\n",
    "#triplet_network_optim = torch.optim.SGD(triplet_network.parameters(), lr=LEARNING_RATE,momentum=0.9 , \n",
    "#                                         weight_decay=Weight_Deacy)\n",
    "\n",
    "attribute_network_scheduler = StepLR(attribute_network_optim , step_size=20000 , gamma=0.5)\n",
    "metric_network_scheduler = StepLR(metric_network_optim , step_size=20000 , gamma=0.5)\n",
    "#\n",
    "print('-'*100)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:41.708691Z",
     "start_time": "2018-10-15T13:46:41.701016Z"
    },
    "collapsed": true,
    "hide_input": true
   },
   "outputs": [],
   "source": [
    "def compute_accuracy(test_features, test_label, test_id, test_attributes):\n",
    "    \n",
    "    test_data = TensorDataset(test_features, test_label)\n",
    "    test_batch = 32\n",
    "    test_loader = DataLoader(test_data, batch_size=test_batch, shuffle=False)\n",
    "    total_rewards = 0\n",
    "\n",
    "    sample_labels = test_id\n",
    "    sample_attributes = test_attributes\n",
    "    class_num = sample_attributes.shape[0]\n",
    "    test_size = test_features.shape[0]\n",
    "\n",
    "    print(\"class num:\", class_num)\n",
    "\n",
    "    for batch_features,batch_labels in test_loader:\n",
    "\n",
    "        batch_size = batch_labels.shape[0]\n",
    "        batch_features_ext = torch.from_numpy(batch_features.numpy().repeat(class_num, 0))\n",
    "        batch_features_ext = metric_network(Variable(batch_features_ext).cuda(GPU).float())  # 32*1024\n",
    "\n",
    "\n",
    "        sample_features = metric_network(attribute_network(Variable(sample_attributes).cuda(GPU).float()))\n",
    "        sample_features_ext = sample_features.repeat(batch_size, 1)\n",
    "\n",
    "\n",
    "        relations = F.pairwise_distance(batch_features_ext, sample_features_ext, 2).view(-1, class_num)\n",
    "        re_batch_labels = []\n",
    "        for label in batch_labels.numpy():\n",
    "            index = np.argwhere(sample_labels == label)\n",
    "            re_batch_labels.append(index[0][0])\n",
    "        re_batch_labels = torch.cuda.LongTensor(re_batch_labels)\n",
    "\n",
    "\n",
    "        _, predict_labels = torch.min(relations.data, 1)\n",
    "        rewards = [1 if predict_labels[j] == re_batch_labels[j] else 0 for j in range(batch_size)]\n",
    "        total_rewards += np.sum(rewards)\n",
    "    test_accuracy = total_rewards/1.0/test_size\n",
    "    return  test_accuracy"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T13:46:41.717083Z",
     "start_time": "2018-10-15T13:46:41.710751Z"
    },
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def compute_accuracy_per_class(test_features, test_label, test_id, test_attributes):\n",
    "    \n",
    "    test_data = TensorDataset(test_features, test_label)\n",
    "    test_batch = 32\n",
    "    test_loader = DataLoader(test_data, batch_size=test_batch, shuffle=False)\n",
    "    total_rewards = 0\n",
    "    #print(test_features.size())\n",
    "    sample_labels = test_id\n",
    "    sample_attributes = test_attributes\n",
    "    class_num = sample_attributes.shape[0]\n",
    "    test_size = test_features.shape[0]\n",
    "    per_class_num = np.zeros(class_num)\n",
    "    per_class_true= np.zeros(class_num)\n",
    "\n",
    "    print(\"class num:\", class_num)\n",
    "\n",
    "    for batch_features,batch_labels in test_loader:\n",
    "\n",
    "        batch_size = batch_labels.shape[0]\n",
    "        batch_features_ext = torch.from_numpy(batch_features.numpy().repeat(class_num, 0))\n",
    "        batch_features_ext = metric_network(Variable(batch_features_ext).cuda(GPU).float())  # 32*1024\n",
    "\n",
    "\n",
    "        sample_features = metric_network(attribute_network(Variable(sample_attributes).cuda(GPU).float()))\n",
    "        sample_features_ext = sample_features.repeat(batch_size, 1)\n",
    "\n",
    "\n",
    "        relations = F.pairwise_distance(batch_features_ext, sample_features_ext, 2).view(-1, class_num)\n",
    "        re_batch_labels = []\n",
    "        for label in batch_labels.numpy():\n",
    "            index = np.argwhere(sample_labels == label)\n",
    "            re_batch_labels.append(index[0][0])\n",
    "        re_batch_labels_id, batch_per_num = np.unique(re_batch_labels , return_counts=True) \n",
    "        re_batch_labels = torch.cuda.LongTensor(re_batch_labels)\n",
    "        \n",
    "        for each in range(re_batch_labels_id.size):\n",
    "            #print(re_batch_labels_id[each])\n",
    "            #print(batch_per_num[each])\n",
    "            per_class_num[re_batch_labels_id[each]] = per_class_num[re_batch_labels_id[each]] + batch_per_num[each]\n",
    "        #print(re_batch_labels_id)\n",
    "        #print('-'*100)\n",
    "        #print(batch_per_num)\n",
    "        #print('-'*100)\n",
    "\n",
    "\n",
    "        _, predict_labels = torch.min(relations.data, 1)\n",
    "        for j in range(batch_size):\n",
    "            if predict_labels[j] == re_batch_labels[j]:\n",
    "                per_class_true[re_batch_labels[j]] = per_class_true[re_batch_labels[j]] + 1\n",
    "            \n",
    "    per_accuracy = per_class_true[np.nonzero(per_class_num)] / per_class_num[np.nonzero(per_class_num)]\n",
    "    \n",
    "\n",
    "    test_accuracy = np.sum(per_accuracy)/1.0/np.count_nonzero(per_class_num)\n",
    "   \n",
    "    #print(np.count_nonzero(per_class_num))\n",
    "    return  test_accuracy"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "ExecuteTime": {
     "end_time": "2018-10-15T15:37:56.866066Z",
     "start_time": "2018-10-15T13:46:41.718014Z"
    },
    "code_folding": [],
    "scrolled": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "training...\n",
      "episode: 1 loss tensor(3.2020, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.14996092534229755\n",
      "gzsl: unseen=0.0000 , seen=0.0103 , h=0.0000\n",
      "____________________________________________________________________________________________________\n",
      "episode: 200 loss tensor(2.9739, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.3249370155778787\n",
      "gzsl: unseen=0.3028 , seen=0.3904 , h=0.3411\n",
      "____________________________________________________________________________________________________\n",
      "episode: 400 loss tensor(2.9538, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.37385449290960926\n",
      "gzsl: unseen=0.3091 , seen=0.6359 , h=0.4160\n",
      "____________________________________________________________________________________________________\n",
      "episode: 600 loss tensor(2.9032, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.3865132712273215\n",
      "gzsl: unseen=0.3056 , seen=0.6485 , h=0.4155\n",
      "____________________________________________________________________________________________________\n",
      "episode: 800 loss tensor(2.8449, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.45356909652769745\n",
      "gzsl: unseen=0.3133 , seen=0.6792 , h=0.4288\n",
      "____________________________________________________________________________________________________\n",
      "episode: 1000 loss tensor(2.7777, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5042270516518916\n",
      "gzsl: unseen=0.3653 , seen=0.7015 , h=0.4804\n",
      "____________________________________________________________________________________________________\n",
      "episode: 1200 loss tensor(2.6597, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.4908124360056393\n",
      "gzsl: unseen=0.3250 , seen=0.6969 , h=0.4433\n",
      "____________________________________________________________________________________________________\n",
      "episode: 1400 loss tensor(2.5648, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5253181649126829\n",
      "gzsl: unseen=0.3491 , seen=0.6636 , h=0.4575\n",
      "____________________________________________________________________________________________________\n",
      "episode: 1600 loss tensor(2.6316, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5247945603903912\n",
      "gzsl: unseen=0.3891 , seen=0.6406 , h=0.4841\n",
      "____________________________________________________________________________________________________\n",
      "episode: 1800 loss tensor(2.5317, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5653437044577696\n",
      "gzsl: unseen=0.4481 , seen=0.6612 , h=0.5342\n",
      "____________________________________________________________________________________________________\n",
      "episode: 2000 loss tensor(2.5334, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5813255425502312\n",
      "gzsl: unseen=0.4533 , seen=0.6340 , h=0.5286\n",
      "____________________________________________________________________________________________________\n",
      "episode: 2200 loss tensor(2.3131, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.5953769954199922\n",
      "gzsl: unseen=0.4635 , seen=0.6688 , h=0.5476\n",
      "____________________________________________________________________________________________________\n",
      "episode: 2400 loss tensor(2.3955, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.602380812722729\n",
      "gzsl: unseen=0.4505 , seen=0.6788 , h=0.5416\n",
      "____________________________________________________________________________________________________\n",
      "episode: 2600 loss tensor(2.0682, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6342135163955771\n",
      "gzsl: unseen=0.4868 , seen=0.6673 , h=0.5629\n",
      "____________________________________________________________________________________________________\n",
      "episode: 2800 loss tensor(2.4959, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6275413929352041\n",
      "gzsl: unseen=0.4688 , seen=0.6804 , h=0.5551\n",
      "____________________________________________________________________________________________________\n",
      "episode: 3000 loss tensor(2.2887, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6266315428998648\n",
      "gzsl: unseen=0.4946 , seen=0.6893 , h=0.5760\n",
      "____________________________________________________________________________________________________\n",
      "episode: 3200 loss tensor(1.9034, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6279964463839856\n",
      "gzsl: unseen=0.5093 , seen=0.6783 , h=0.5818\n",
      "____________________________________________________________________________________________________\n",
      "episode: 3400 loss tensor(2.1899, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6334364646234903\n",
      "gzsl: unseen=0.5052 , seen=0.6879 , h=0.5826\n",
      "____________________________________________________________________________________________________\n",
      "episode: 3600 loss tensor(2.1923, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6340685078473045\n",
      "gzsl: unseen=0.5000 , seen=0.6926 , h=0.5807\n",
      "____________________________________________________________________________________________________\n",
      "episode: 3800 loss tensor(1.8063, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6334706121171603\n",
      "gzsl: unseen=0.4970 , seen=0.6944 , h=0.5794\n",
      "____________________________________________________________________________________________________\n",
      "episode: 4000 loss tensor(2.0460, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6345901647985576\n",
      "gzsl: unseen=0.5039 , seen=0.7036 , h=0.5872\n",
      "____________________________________________________________________________________________________\n",
      "episode: 4200 loss tensor(2.0571, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6550607523496248\n",
      "gzsl: unseen=0.5263 , seen=0.7162 , h=0.6067\n",
      "____________________________________________________________________________________________________\n",
      "episode: 4400 loss tensor(2.1346, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6456559451949081\n",
      "gzsl: unseen=0.5032 , seen=0.7283 , h=0.5952\n",
      "____________________________________________________________________________________________________\n",
      "episode: 4600 loss tensor(1.7971, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6556850491747934\n",
      "gzsl: unseen=0.5176 , seen=0.7302 , h=0.6058\n",
      "____________________________________________________________________________________________________\n",
      "episode: 4800 loss tensor(2.1429, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6500092988317233\n",
      "gzsl: unseen=0.4897 , seen=0.7253 , h=0.5847\n",
      "____________________________________________________________________________________________________\n",
      "episode: 5000 loss tensor(1.8512, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6698679840209578\n",
      "gzsl: unseen=0.4966 , seen=0.7228 , h=0.5887\n",
      "____________________________________________________________________________________________________\n",
      "episode: 5200 loss tensor(2.5487, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6502965188644169\n",
      "gzsl: unseen=0.5253 , seen=0.7296 , h=0.6108\n",
      "____________________________________________________________________________________________________\n",
      "episode: 5400 loss tensor(2.2489, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6664831437900214\n",
      "gzsl: unseen=0.5091 , seen=0.7323 , h=0.6006\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 5600 loss tensor(1.9507, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6528819367883744\n",
      "gzsl: unseen=0.5095 , seen=0.7463 , h=0.6055\n",
      "____________________________________________________________________________________________________\n",
      "episode: 5800 loss tensor(2.3037, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6457662641456092\n",
      "gzsl: unseen=0.4992 , seen=0.7463 , h=0.5983\n",
      "____________________________________________________________________________________________________\n",
      "episode: 6000 loss tensor(1.9639, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6496830317158968\n",
      "gzsl: unseen=0.5242 , seen=0.7474 , h=0.6162\n",
      "____________________________________________________________________________________________________\n",
      "episode: 6200 loss tensor(1.9569, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6633598764681249\n",
      "gzsl: unseen=0.5295 , seen=0.7450 , h=0.6190\n",
      "____________________________________________________________________________________________________\n",
      "episode: 6400 loss tensor(2.0423, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6430746150543069\n",
      "gzsl: unseen=0.5082 , seen=0.7526 , h=0.6067\n",
      "____________________________________________________________________________________________________\n",
      "episode: 6600 loss tensor(1.5279, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.630619565882669\n",
      "gzsl: unseen=0.5158 , seen=0.7439 , h=0.6092\n",
      "____________________________________________________________________________________________________\n",
      "episode: 6800 loss tensor(1.7428, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6509766778460846\n",
      "gzsl: unseen=0.5181 , seen=0.7440 , h=0.6108\n",
      "____________________________________________________________________________________________________\n",
      "episode: 7000 loss tensor(1.7759, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6607199632580435\n",
      "gzsl: unseen=0.5368 , seen=0.7519 , h=0.6264\n",
      "____________________________________________________________________________________________________\n",
      "episode: 7200 loss tensor(1.8390, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6551511565968912\n",
      "gzsl: unseen=0.5080 , seen=0.7515 , h=0.6062\n",
      "____________________________________________________________________________________________________\n",
      "episode: 7400 loss tensor(1.6705, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6438140975131741\n",
      "gzsl: unseen=0.5094 , seen=0.7568 , h=0.6089\n",
      "____________________________________________________________________________________________________\n",
      "episode: 7600 loss tensor(2.2630, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6563893932098437\n",
      "gzsl: unseen=0.5236 , seen=0.7539 , h=0.6180\n",
      "____________________________________________________________________________________________________\n",
      "episode: 7800 loss tensor(1.6925, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6495361029000145\n",
      "gzsl: unseen=0.5147 , seen=0.7665 , h=0.6159\n",
      "____________________________________________________________________________________________________\n",
      "episode: 8000 loss tensor(1.6118, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6574337174488225\n",
      "gzsl: unseen=0.5403 , seen=0.7535 , h=0.6293\n",
      "____________________________________________________________________________________________________\n",
      "episode: 8200 loss tensor(2.3421, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6532361884837428\n",
      "gzsl: unseen=0.5271 , seen=0.7670 , h=0.6248\n",
      "____________________________________________________________________________________________________\n",
      "episode: 8400 loss tensor(1.8144, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6617113609917069\n",
      "gzsl: unseen=0.5328 , seen=0.7696 , h=0.6297\n",
      "____________________________________________________________________________________________________\n",
      "episode: 8600 loss tensor(1.6273, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6529761391966084\n",
      "gzsl: unseen=0.5205 , seen=0.7679 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 8800 loss tensor(1.7213, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6513214436373344\n",
      "gzsl: unseen=0.5059 , seen=0.7717 , h=0.6111\n",
      "____________________________________________________________________________________________________\n",
      "episode: 9000 loss tensor(1.6879, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6692186248267611\n",
      "gzsl: unseen=0.5482 , seen=0.7624 , h=0.6378\n",
      "____________________________________________________________________________________________________\n",
      "episode: 9200 loss tensor(1.7203, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.652469457926798\n",
      "gzsl: unseen=0.5309 , seen=0.7740 , h=0.6298\n",
      "____________________________________________________________________________________________________\n",
      "episode: 9400 loss tensor(2.1123, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6683527945648504\n",
      "gzsl: unseen=0.5458 , seen=0.7739 , h=0.6402\n",
      "____________________________________________________________________________________________________\n",
      "episode: 9600 loss tensor(1.7880, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6674145197887136\n",
      "gzsl: unseen=0.5491 , seen=0.7665 , h=0.6398\n",
      "____________________________________________________________________________________________________\n",
      "episode: 9800 loss tensor(1.5722, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6670327715189304\n",
      "gzsl: unseen=0.5544 , seen=0.7781 , h=0.6474\n",
      "____________________________________________________________________________________________________\n",
      "episode: 10000 loss tensor(1.5144, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6805613285883648\n",
      "gzsl: unseen=0.5562 , seen=0.7795 , h=0.6492\n",
      "____________________________________________________________________________________________________\n",
      "episode: 10200 loss tensor(1.8941, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6502260497060992\n",
      "gzsl: unseen=0.5297 , seen=0.7763 , h=0.6297\n",
      "____________________________________________________________________________________________________\n",
      "episode: 10400 loss tensor(1.2726, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.663089437631377\n",
      "gzsl: unseen=0.5306 , seen=0.7836 , h=0.6327\n",
      "____________________________________________________________________________________________________\n",
      "episode: 10600 loss tensor(1.3605, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6472738089927844\n",
      "gzsl: unseen=0.5045 , seen=0.7786 , h=0.6123\n",
      "____________________________________________________________________________________________________\n",
      "episode: 10800 loss tensor(2.1712, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6646338747668917\n",
      "gzsl: unseen=0.5289 , seen=0.7753 , h=0.6288\n",
      "____________________________________________________________________________________________________\n",
      "episode: 11000 loss tensor(1.6496, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6479817762549399\n",
      "gzsl: unseen=0.5073 , seen=0.7858 , h=0.6166\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 11200 loss tensor(2.0164, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6624556532639181\n",
      "gzsl: unseen=0.5372 , seen=0.7818 , h=0.6368\n",
      "____________________________________________________________________________________________________\n",
      "episode: 11400 loss tensor(2.0533, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6553097591187828\n",
      "gzsl: unseen=0.5063 , seen=0.7887 , h=0.6167\n",
      "____________________________________________________________________________________________________\n",
      "episode: 11600 loss tensor(2.0423, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6533328474506517\n",
      "gzsl: unseen=0.5223 , seen=0.7857 , h=0.6275\n",
      "____________________________________________________________________________________________________\n",
      "episode: 11800 loss tensor(1.8976, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6712979443997851\n",
      "gzsl: unseen=0.5483 , seen=0.7835 , h=0.6451\n",
      "____________________________________________________________________________________________________\n",
      "episode: 12000 loss tensor(1.9285, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6702033426728129\n",
      "gzsl: unseen=0.5290 , seen=0.7869 , h=0.6327\n",
      "____________________________________________________________________________________________________\n",
      "episode: 12200 loss tensor(2.5681, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6355672191394077\n",
      "gzsl: unseen=0.5152 , seen=0.7909 , h=0.6239\n",
      "____________________________________________________________________________________________________\n",
      "episode: 12400 loss tensor(1.3606, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6558001037437788\n",
      "gzsl: unseen=0.5334 , seen=0.7901 , h=0.6368\n",
      "____________________________________________________________________________________________________\n",
      "episode: 12600 loss tensor(2.4475, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6544739238589208\n",
      "gzsl: unseen=0.5240 , seen=0.7888 , h=0.6297\n",
      "____________________________________________________________________________________________________\n",
      "episode: 12800 loss tensor(2.0887, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6718528519751952\n",
      "gzsl: unseen=0.5361 , seen=0.7942 , h=0.6401\n",
      "____________________________________________________________________________________________________\n",
      "episode: 13000 loss tensor(2.5425, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6534667725570682\n",
      "gzsl: unseen=0.5318 , seen=0.7873 , h=0.6348\n",
      "____________________________________________________________________________________________________\n",
      "episode: 13200 loss tensor(2.0829, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6735591245373531\n",
      "gzsl: unseen=0.5445 , seen=0.7903 , h=0.6448\n",
      "____________________________________________________________________________________________________\n",
      "episode: 13400 loss tensor(2.1861, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6739053570374136\n",
      "gzsl: unseen=0.5370 , seen=0.7846 , h=0.6376\n",
      "____________________________________________________________________________________________________\n",
      "episode: 13600 loss tensor(2.3205, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6721853471293397\n",
      "gzsl: unseen=0.5444 , seen=0.7802 , h=0.6413\n",
      "____________________________________________________________________________________________________\n",
      "episode: 13800 loss tensor(1.7516, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6670995342270397\n",
      "gzsl: unseen=0.5366 , seen=0.7859 , h=0.6378\n",
      "____________________________________________________________________________________________________\n",
      "episode: 14000 loss tensor(2.5187, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6417034562428061\n",
      "gzsl: unseen=0.5065 , seen=0.7890 , h=0.6170\n",
      "____________________________________________________________________________________________________\n",
      "episode: 14200 loss tensor(1.9066, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.655422575590603\n",
      "gzsl: unseen=0.5227 , seen=0.7920 , h=0.6297\n",
      "____________________________________________________________________________________________________\n",
      "episode: 14400 loss tensor(2.3707, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6473997646658307\n",
      "gzsl: unseen=0.5226 , seen=0.7907 , h=0.6293\n",
      "____________________________________________________________________________________________________\n",
      "episode: 14600 loss tensor(1.6136, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6595240200029048\n",
      "gzsl: unseen=0.5248 , seen=0.7990 , h=0.6335\n",
      "____________________________________________________________________________________________________\n",
      "episode: 14800 loss tensor(1.5702, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.668384178650689\n",
      "gzsl: unseen=0.5458 , seen=0.7930 , h=0.6466\n",
      "____________________________________________________________________________________________________\n",
      "episode: 15000 loss tensor(2.2875, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6620977806205888\n",
      "gzsl: unseen=0.5205 , seen=0.8011 , h=0.6310\n",
      "____________________________________________________________________________________________________\n",
      "episode: 15200 loss tensor(2.4607, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6789318325815932\n",
      "gzsl: unseen=0.5393 , seen=0.7951 , h=0.6427\n",
      "____________________________________________________________________________________________________\n",
      "episode: 15400 loss tensor(1.9811, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6611799975383573\n",
      "gzsl: unseen=0.5254 , seen=0.7920 , h=0.6317\n",
      "____________________________________________________________________________________________________\n",
      "episode: 15600 loss tensor(1.8874, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6696564922030779\n",
      "gzsl: unseen=0.5051 , seen=0.8055 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 15800 loss tensor(2.5866, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6617368919631558\n",
      "gzsl: unseen=0.5267 , seen=0.7962 , h=0.6340\n",
      "____________________________________________________________________________________________________\n",
      "episode: 16000 loss tensor(2.1174, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6724291104358511\n",
      "gzsl: unseen=0.5179 , seen=0.8040 , h=0.6300\n",
      "____________________________________________________________________________________________________\n",
      "episode: 16200 loss tensor(1.9292, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6634201931226572\n",
      "gzsl: unseen=0.5206 , seen=0.7919 , h=0.6282\n",
      "____________________________________________________________________________________________________\n",
      "episode: 16400 loss tensor(1.6920, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6630845104185135\n",
      "gzsl: unseen=0.5180 , seen=0.7995 , h=0.6287\n",
      "____________________________________________________________________________________________________\n",
      "episode: 16600 loss tensor(2.0873, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6851987692780602\n",
      "gzsl: unseen=0.5394 , seen=0.7973 , h=0.6434\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 16800 loss tensor(1.6674, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6732120622015818\n",
      "gzsl: unseen=0.5427 , seen=0.7953 , h=0.6451\n",
      "____________________________________________________________________________________________________\n",
      "episode: 17000 loss tensor(1.6067, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6750611794436817\n",
      "gzsl: unseen=0.5290 , seen=0.7927 , h=0.6345\n",
      "____________________________________________________________________________________________________\n",
      "episode: 17200 loss tensor(2.8439, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6534917641793208\n",
      "gzsl: unseen=0.4931 , seen=0.8096 , h=0.6129\n",
      "____________________________________________________________________________________________________\n",
      "episode: 17400 loss tensor(1.7563, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.653483955074256\n",
      "gzsl: unseen=0.5038 , seen=0.8023 , h=0.6190\n",
      "____________________________________________________________________________________________________\n",
      "episode: 17600 loss tensor(1.1343, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.671471286262307\n",
      "gzsl: unseen=0.5125 , seen=0.8070 , h=0.6269\n",
      "____________________________________________________________________________________________________\n",
      "episode: 17800 loss tensor(2.0005, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6832783784615296\n",
      "gzsl: unseen=0.5259 , seen=0.8040 , h=0.6359\n",
      "____________________________________________________________________________________________________\n",
      "episode: 18000 loss tensor(2.2417, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6674964883199314\n",
      "gzsl: unseen=0.5120 , seen=0.8036 , h=0.6255\n",
      "____________________________________________________________________________________________________\n",
      "episode: 18200 loss tensor(2.4320, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6640894809940676\n",
      "gzsl: unseen=0.5110 , seen=0.8001 , h=0.6237\n",
      "____________________________________________________________________________________________________\n",
      "episode: 18400 loss tensor(1.7425, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6599916835793687\n",
      "gzsl: unseen=0.5040 , seen=0.8032 , h=0.6193\n",
      "____________________________________________________________________________________________________\n",
      "episode: 18600 loss tensor(1.6599, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6477808469206309\n",
      "gzsl: unseen=0.5074 , seen=0.8039 , h=0.6222\n",
      "____________________________________________________________________________________________________\n",
      "episode: 18800 loss tensor(1.3045, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6628169260795559\n",
      "gzsl: unseen=0.5400 , seen=0.7988 , h=0.6444\n",
      "____________________________________________________________________________________________________\n",
      "episode: 19000 loss tensor(1.5935, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6750817254747861\n",
      "gzsl: unseen=0.5316 , seen=0.8008 , h=0.6390\n",
      "____________________________________________________________________________________________________\n",
      "episode: 19200 loss tensor(2.3461, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6443534507788555\n",
      "gzsl: unseen=0.5019 , seen=0.8002 , h=0.6169\n",
      "____________________________________________________________________________________________________\n",
      "episode: 19400 loss tensor(2.2559, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.663308902143108\n",
      "gzsl: unseen=0.5315 , seen=0.7985 , h=0.6382\n",
      "____________________________________________________________________________________________________\n",
      "episode: 19600 loss tensor(2.0872, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6652538653831978\n",
      "gzsl: unseen=0.5384 , seen=0.7981 , h=0.6430\n",
      "____________________________________________________________________________________________________\n",
      "episode: 19800 loss tensor(2.1419, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6770413365200261\n",
      "gzsl: unseen=0.5145 , seen=0.8112 , h=0.6296\n",
      "____________________________________________________________________________________________________\n",
      "episode: 20000 loss tensor(2.2835, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6604522758184282\n",
      "gzsl: unseen=0.5318 , seen=0.8048 , h=0.6404\n",
      "____________________________________________________________________________________________________\n",
      "episode: 20200 loss tensor(2.9453, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6593807811584528\n",
      "gzsl: unseen=0.5322 , seen=0.8011 , h=0.6396\n",
      "____________________________________________________________________________________________________\n",
      "episode: 20400 loss tensor(2.6625, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6634507702282809\n",
      "gzsl: unseen=0.5275 , seen=0.8004 , h=0.6359\n",
      "____________________________________________________________________________________________________\n",
      "episode: 20600 loss tensor(1.4653, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6622382663997621\n",
      "gzsl: unseen=0.5294 , seen=0.8021 , h=0.6378\n",
      "____________________________________________________________________________________________________\n",
      "episode: 20800 loss tensor(2.2075, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6602203900683065\n",
      "gzsl: unseen=0.5318 , seen=0.8011 , h=0.6393\n",
      "____________________________________________________________________________________________________\n",
      "episode: 21000 loss tensor(2.3256, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.666144919709314\n",
      "gzsl: unseen=0.5342 , seen=0.8006 , h=0.6408\n",
      "____________________________________________________________________________________________________\n",
      "episode: 21200 loss tensor(1.9318, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6548151549136597\n",
      "gzsl: unseen=0.5210 , seen=0.8078 , h=0.6334\n",
      "____________________________________________________________________________________________________\n",
      "episode: 21400 loss tensor(2.0433, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6582676476718907\n",
      "gzsl: unseen=0.5250 , seen=0.8029 , h=0.6349\n",
      "____________________________________________________________________________________________________\n",
      "episode: 21600 loss tensor(1.3485, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6664647346639542\n",
      "gzsl: unseen=0.5273 , seen=0.8029 , h=0.6365\n",
      "____________________________________________________________________________________________________\n",
      "episode: 21800 loss tensor(1.7971, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6592453280891568\n",
      "gzsl: unseen=0.5182 , seen=0.8034 , h=0.6301\n",
      "____________________________________________________________________________________________________\n",
      "episode: 22000 loss tensor(1.7790, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6652961455613582\n",
      "gzsl: unseen=0.5034 , seen=0.8138 , h=0.6221\n",
      "____________________________________________________________________________________________________\n",
      "episode: 22200 loss tensor(1.5512, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6581522770884065\n",
      "gzsl: unseen=0.5114 , seen=0.8077 , h=0.6263\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 22400 loss tensor(1.4668, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6461268468182688\n",
      "gzsl: unseen=0.5006 , seen=0.8079 , h=0.6181\n",
      "____________________________________________________________________________________________________\n",
      "episode: 22600 loss tensor(1.8641, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.671134870641126\n",
      "gzsl: unseen=0.5231 , seen=0.8048 , h=0.6341\n",
      "____________________________________________________________________________________________________\n",
      "episode: 22800 loss tensor(2.6038, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6733675975950806\n",
      "gzsl: unseen=0.5174 , seen=0.8032 , h=0.6294\n",
      "____________________________________________________________________________________________________\n",
      "episode: 23000 loss tensor(2.2459, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6620268948449206\n",
      "gzsl: unseen=0.5126 , seen=0.8089 , h=0.6275\n",
      "____________________________________________________________________________________________________\n",
      "episode: 23200 loss tensor(3.2457, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6677865017930149\n",
      "gzsl: unseen=0.5234 , seen=0.8078 , h=0.6352\n",
      "____________________________________________________________________________________________________\n",
      "episode: 23400 loss tensor(2.4212, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6696234077350157\n",
      "gzsl: unseen=0.5214 , seen=0.8068 , h=0.6335\n",
      "____________________________________________________________________________________________________\n",
      "episode: 23600 loss tensor(1.3915, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6733151593738518\n",
      "gzsl: unseen=0.5256 , seen=0.8146 , h=0.6389\n",
      "____________________________________________________________________________________________________\n",
      "episode: 23800 loss tensor(2.4269, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6703717736089568\n",
      "gzsl: unseen=0.5189 , seen=0.8104 , h=0.6327\n",
      "____________________________________________________________________________________________________\n",
      "episode: 24000 loss tensor(2.3898, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.676799104103148\n",
      "gzsl: unseen=0.5248 , seen=0.8170 , h=0.6391\n",
      "____________________________________________________________________________________________________\n",
      "episode: 24200 loss tensor(3.1025, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6605913011596355\n",
      "gzsl: unseen=0.5072 , seen=0.8084 , h=0.6233\n",
      "____________________________________________________________________________________________________\n",
      "episode: 24400 loss tensor(1.2625, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6493599011670541\n",
      "gzsl: unseen=0.5060 , seen=0.8033 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 24600 loss tensor(2.2987, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6591569046871403\n",
      "gzsl: unseen=0.5207 , seen=0.8060 , h=0.6327\n",
      "____________________________________________________________________________________________________\n",
      "episode: 24800 loss tensor(1.5732, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6606443695417324\n",
      "gzsl: unseen=0.5161 , seen=0.8105 , h=0.6306\n",
      "____________________________________________________________________________________________________\n",
      "episode: 25000 loss tensor(2.2653, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6744983802881153\n",
      "gzsl: unseen=0.5202 , seen=0.8094 , h=0.6333\n",
      "____________________________________________________________________________________________________\n",
      "episode: 25200 loss tensor(1.5780, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6810643391510581\n",
      "gzsl: unseen=0.5248 , seen=0.8112 , h=0.6373\n",
      "____________________________________________________________________________________________________\n",
      "episode: 25400 loss tensor(1.4100, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6758569886810903\n",
      "gzsl: unseen=0.5295 , seen=0.8164 , h=0.6424\n",
      "____________________________________________________________________________________________________\n",
      "episode: 25600 loss tensor(1.8270, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6553087161901714\n",
      "gzsl: unseen=0.5182 , seen=0.8043 , h=0.6303\n",
      "____________________________________________________________________________________________________\n",
      "episode: 25800 loss tensor(1.8515, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6651461492110935\n",
      "gzsl: unseen=0.5321 , seen=0.8077 , h=0.6416\n",
      "____________________________________________________________________________________________________\n",
      "episode: 26000 loss tensor(1.6753, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.662594228107938\n",
      "gzsl: unseen=0.5216 , seen=0.8140 , h=0.6358\n",
      "____________________________________________________________________________________________________\n",
      "episode: 26200 loss tensor(2.7478, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6671611906719316\n",
      "gzsl: unseen=0.5141 , seen=0.8148 , h=0.6304\n",
      "____________________________________________________________________________________________________\n",
      "episode: 26400 loss tensor(1.6304, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6632759984135521\n",
      "gzsl: unseen=0.5135 , seen=0.8101 , h=0.6286\n",
      "____________________________________________________________________________________________________\n",
      "episode: 26600 loss tensor(1.5239, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6677985170919791\n",
      "gzsl: unseen=0.5115 , seen=0.8202 , h=0.6301\n",
      "____________________________________________________________________________________________________\n",
      "episode: 26800 loss tensor(1.6425, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6691140471356675\n",
      "gzsl: unseen=0.5133 , seen=0.8162 , h=0.6302\n",
      "____________________________________________________________________________________________________\n",
      "episode: 27000 loss tensor(1.5578, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6524076605478106\n",
      "gzsl: unseen=0.4977 , seen=0.8143 , h=0.6178\n",
      "____________________________________________________________________________________________________\n",
      "episode: 27200 loss tensor(1.7417, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6634301803554028\n",
      "gzsl: unseen=0.5192 , seen=0.8116 , h=0.6333\n",
      "____________________________________________________________________________________________________\n",
      "episode: 27400 loss tensor(1.2929, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6628454348219837\n",
      "gzsl: unseen=0.5173 , seen=0.8067 , h=0.6304\n",
      "____________________________________________________________________________________________________\n",
      "episode: 27600 loss tensor(1.0288, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6604199270131227\n",
      "gzsl: unseen=0.5086 , seen=0.8065 , h=0.6238\n",
      "____________________________________________________________________________________________________\n",
      "episode: 27800 loss tensor(2.6977, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6731196831652408\n",
      "gzsl: unseen=0.5347 , seen=0.8081 , h=0.6436\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 28000 loss tensor(1.4513, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6708405253617802\n",
      "gzsl: unseen=0.5285 , seen=0.8069 , h=0.6387\n",
      "____________________________________________________________________________________________________\n",
      "episode: 28200 loss tensor(2.3844, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6693411938197682\n",
      "gzsl: unseen=0.5260 , seen=0.8063 , h=0.6367\n",
      "____________________________________________________________________________________________________\n",
      "episode: 28400 loss tensor(2.7031, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6754735008107393\n",
      "gzsl: unseen=0.5331 , seen=0.8038 , h=0.6410\n",
      "____________________________________________________________________________________________________\n",
      "episode: 28600 loss tensor(2.2912, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6627717165021674\n",
      "gzsl: unseen=0.5309 , seen=0.8078 , h=0.6407\n",
      "____________________________________________________________________________________________________\n",
      "episode: 28800 loss tensor(2.2233, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6582271084992033\n",
      "gzsl: unseen=0.5196 , seen=0.8072 , h=0.6323\n",
      "____________________________________________________________________________________________________\n",
      "episode: 29000 loss tensor(2.1865, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6553401073853864\n",
      "gzsl: unseen=0.5032 , seen=0.8089 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 29200 loss tensor(1.5223, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6599550093705402\n",
      "gzsl: unseen=0.5301 , seen=0.8013 , h=0.6381\n",
      "____________________________________________________________________________________________________\n",
      "episode: 29400 loss tensor(0.7724, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6621638869669488\n",
      "gzsl: unseen=0.5204 , seen=0.8068 , h=0.6327\n",
      "____________________________________________________________________________________________________\n",
      "episode: 29600 loss tensor(1.3738, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6560240041473547\n",
      "gzsl: unseen=0.5141 , seen=0.8059 , h=0.6277\n",
      "____________________________________________________________________________________________________\n",
      "episode: 29800 loss tensor(1.4920, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6561104480773355\n",
      "gzsl: unseen=0.5065 , seen=0.8123 , h=0.6240\n",
      "____________________________________________________________________________________________________\n",
      "episode: 30000 loss tensor(0.6173, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6421962008989454\n",
      "gzsl: unseen=0.4911 , seen=0.8076 , h=0.6108\n",
      "____________________________________________________________________________________________________\n",
      "episode: 30200 loss tensor(1.8151, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6500224129812713\n",
      "gzsl: unseen=0.5116 , seen=0.8060 , h=0.6259\n",
      "____________________________________________________________________________________________________\n",
      "episode: 30400 loss tensor(2.7438, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6810089888760262\n",
      "gzsl: unseen=0.5403 , seen=0.8112 , h=0.6486\n",
      "____________________________________________________________________________________________________\n",
      "episode: 30600 loss tensor(2.0713, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6649667605774428\n",
      "gzsl: unseen=0.5348 , seen=0.8058 , h=0.6429\n",
      "____________________________________________________________________________________________________\n",
      "episode: 30800 loss tensor(3.1680, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6655997758632142\n",
      "gzsl: unseen=0.5351 , seen=0.8072 , h=0.6436\n",
      "____________________________________________________________________________________________________\n",
      "episode: 31000 loss tensor(1.1395, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.674050111335916\n",
      "gzsl: unseen=0.5393 , seen=0.8103 , h=0.6476\n",
      "____________________________________________________________________________________________________\n",
      "episode: 31200 loss tensor(2.5112, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6635394970720151\n",
      "gzsl: unseen=0.5251 , seen=0.8090 , h=0.6369\n",
      "____________________________________________________________________________________________________\n",
      "episode: 31400 loss tensor(1.5809, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6521326643091204\n",
      "gzsl: unseen=0.5132 , seen=0.8138 , h=0.6294\n",
      "____________________________________________________________________________________________________\n",
      "episode: 31600 loss tensor(1.3225, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6596383479814782\n",
      "gzsl: unseen=0.5125 , seen=0.8083 , h=0.6273\n",
      "____________________________________________________________________________________________________\n",
      "episode: 31800 loss tensor(2.8175, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.65876946031006\n",
      "gzsl: unseen=0.5092 , seen=0.8075 , h=0.6246\n",
      "____________________________________________________________________________________________________\n",
      "episode: 32000 loss tensor(1.4778, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6608008681829148\n",
      "gzsl: unseen=0.5172 , seen=0.8050 , h=0.6298\n",
      "____________________________________________________________________________________________________\n",
      "episode: 32200 loss tensor(0.7722, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.652378622981281\n",
      "gzsl: unseen=0.5110 , seen=0.8043 , h=0.6249\n",
      "____________________________________________________________________________________________________\n",
      "episode: 32400 loss tensor(1.7202, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6519752604717659\n",
      "gzsl: unseen=0.5055 , seen=0.8072 , h=0.6217\n",
      "____________________________________________________________________________________________________\n",
      "episode: 32600 loss tensor(1.8428, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6660656516705089\n",
      "gzsl: unseen=0.5292 , seen=0.8020 , h=0.6377\n",
      "____________________________________________________________________________________________________\n",
      "episode: 32800 loss tensor(1.4255, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6566132854830864\n",
      "gzsl: unseen=0.5141 , seen=0.8063 , h=0.6279\n",
      "____________________________________________________________________________________________________\n",
      "episode: 33000 loss tensor(3.5916, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6504592075776285\n",
      "gzsl: unseen=0.5209 , seen=0.8089 , h=0.6337\n",
      "____________________________________________________________________________________________________\n",
      "episode: 33200 loss tensor(1.9431, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.653469641927197\n",
      "gzsl: unseen=0.5191 , seen=0.8078 , h=0.6321\n",
      "____________________________________________________________________________________________________\n",
      "episode: 33400 loss tensor(1.7462, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6598863869313258\n",
      "gzsl: unseen=0.5137 , seen=0.8129 , h=0.6296\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 33600 loss tensor(0.6407, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6559373116926046\n",
      "gzsl: unseen=0.5059 , seen=0.8144 , h=0.6241\n",
      "____________________________________________________________________________________________________\n",
      "episode: 33800 loss tensor(2.1055, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6589941593874717\n",
      "gzsl: unseen=0.5086 , seen=0.8101 , h=0.6249\n",
      "____________________________________________________________________________________________________\n",
      "episode: 34000 loss tensor(1.7356, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6560707897341004\n",
      "gzsl: unseen=0.5182 , seen=0.8100 , h=0.6321\n",
      "____________________________________________________________________________________________________\n",
      "episode: 34200 loss tensor(1.5755, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6531854566394243\n",
      "gzsl: unseen=0.5091 , seen=0.8139 , h=0.6264\n",
      "____________________________________________________________________________________________________\n",
      "episode: 34400 loss tensor(0.8604, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6570808532395948\n",
      "gzsl: unseen=0.5185 , seen=0.8137 , h=0.6334\n",
      "____________________________________________________________________________________________________\n",
      "episode: 34600 loss tensor(2.1370, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6474724081212055\n",
      "gzsl: unseen=0.5057 , seen=0.8062 , h=0.6215\n",
      "____________________________________________________________________________________________________\n",
      "episode: 34800 loss tensor(1.8955, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.664098422292709\n",
      "gzsl: unseen=0.5366 , seen=0.8082 , h=0.6450\n",
      "____________________________________________________________________________________________________\n",
      "episode: 35000 loss tensor(2.2294, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6729313249070631\n",
      "gzsl: unseen=0.5220 , seen=0.8108 , h=0.6351\n",
      "____________________________________________________________________________________________________\n",
      "episode: 35200 loss tensor(1.9562, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.662971068798899\n",
      "gzsl: unseen=0.5247 , seen=0.8016 , h=0.6342\n",
      "____________________________________________________________________________________________________\n",
      "episode: 35400 loss tensor(2.0122, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6564691159087566\n",
      "gzsl: unseen=0.5080 , seen=0.8102 , h=0.6245\n",
      "____________________________________________________________________________________________________\n",
      "episode: 35600 loss tensor(1.7164, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6546650733507742\n",
      "gzsl: unseen=0.5061 , seen=0.8151 , h=0.6244\n",
      "____________________________________________________________________________________________________\n",
      "episode: 35800 loss tensor(0.9927, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.650350481869135\n",
      "gzsl: unseen=0.4987 , seen=0.8111 , h=0.6176\n",
      "____________________________________________________________________________________________________\n",
      "episode: 36000 loss tensor(2.0253, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6452349082829442\n",
      "gzsl: unseen=0.5072 , seen=0.8144 , h=0.6251\n",
      "____________________________________________________________________________________________________\n",
      "episode: 36200 loss tensor(1.4796, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6600263530926\n",
      "gzsl: unseen=0.5244 , seen=0.8093 , h=0.6364\n",
      "____________________________________________________________________________________________________\n",
      "episode: 36400 loss tensor(1.6749, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6511266834840848\n",
      "gzsl: unseen=0.4890 , seen=0.8159 , h=0.6115\n",
      "____________________________________________________________________________________________________\n",
      "episode: 36600 loss tensor(1.2061, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6580377862528386\n",
      "gzsl: unseen=0.5169 , seen=0.8088 , h=0.6307\n",
      "____________________________________________________________________________________________________\n",
      "episode: 36800 loss tensor(2.3027, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6632336993511025\n",
      "gzsl: unseen=0.5228 , seen=0.8089 , h=0.6351\n",
      "____________________________________________________________________________________________________\n",
      "episode: 37000 loss tensor(0.7409, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6503590884005643\n",
      "gzsl: unseen=0.5014 , seen=0.8103 , h=0.6194\n",
      "____________________________________________________________________________________________________\n",
      "episode: 37200 loss tensor(1.4998, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.639518798835206\n",
      "gzsl: unseen=0.4859 , seen=0.8156 , h=0.6090\n",
      "____________________________________________________________________________________________________\n",
      "episode: 37400 loss tensor(2.7827, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6433890515613497\n",
      "gzsl: unseen=0.4945 , seen=0.8083 , h=0.6136\n",
      "____________________________________________________________________________________________________\n",
      "episode: 37600 loss tensor(1.4996, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6513089368025788\n",
      "gzsl: unseen=0.4911 , seen=0.8157 , h=0.6131\n",
      "____________________________________________________________________________________________________\n",
      "episode: 37800 loss tensor(1.2904, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6549817374133643\n",
      "gzsl: unseen=0.5073 , seen=0.8123 , h=0.6246\n",
      "____________________________________________________________________________________________________\n",
      "episode: 38000 loss tensor(1.4888, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6661289810307738\n",
      "gzsl: unseen=0.5264 , seen=0.8082 , h=0.6375\n",
      "____________________________________________________________________________________________________\n",
      "episode: 38200 loss tensor(1.6322, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6661126736175744\n",
      "gzsl: unseen=0.5206 , seen=0.8117 , h=0.6343\n",
      "____________________________________________________________________________________________________\n",
      "episode: 38400 loss tensor(2.2282, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.660082822778343\n",
      "gzsl: unseen=0.5136 , seen=0.8052 , h=0.6272\n",
      "____________________________________________________________________________________________________\n",
      "episode: 38600 loss tensor(2.3455, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6614253860192127\n",
      "gzsl: unseen=0.5134 , seen=0.8129 , h=0.6293\n",
      "____________________________________________________________________________________________________\n",
      "episode: 38800 loss tensor(1.9074, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6664708901922343\n",
      "gzsl: unseen=0.5349 , seen=0.8060 , h=0.6430\n",
      "____________________________________________________________________________________________________\n",
      "episode: 39000 loss tensor(1.9763, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6572126172169399\n",
      "gzsl: unseen=0.5171 , seen=0.8100 , h=0.6312\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 39200 loss tensor(1.9181, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6572571521458601\n",
      "gzsl: unseen=0.5140 , seen=0.8124 , h=0.6296\n",
      "____________________________________________________________________________________________________\n",
      "episode: 39400 loss tensor(1.7724, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6548654373577366\n",
      "gzsl: unseen=0.5133 , seen=0.8077 , h=0.6277\n",
      "____________________________________________________________________________________________________\n",
      "episode: 39600 loss tensor(2.7764, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6618330393364256\n",
      "gzsl: unseen=0.5115 , seen=0.8151 , h=0.6285\n",
      "____________________________________________________________________________________________________\n",
      "episode: 39800 loss tensor(2.1763, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6448008034364494\n",
      "gzsl: unseen=0.4886 , seen=0.8155 , h=0.6111\n",
      "____________________________________________________________________________________________________\n",
      "episode: 40000 loss tensor(2.0926, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6493044621044769\n",
      "gzsl: unseen=0.5100 , seen=0.8072 , h=0.6251\n",
      "____________________________________________________________________________________________________\n",
      "episode: 40200 loss tensor(2.4172, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6522637828117939\n",
      "gzsl: unseen=0.5176 , seen=0.8071 , h=0.6307\n",
      "____________________________________________________________________________________________________\n",
      "episode: 40400 loss tensor(1.1446, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.650705901737777\n",
      "gzsl: unseen=0.5176 , seen=0.8070 , h=0.6307\n",
      "____________________________________________________________________________________________________\n",
      "episode: 40600 loss tensor(2.3482, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.648579184130605\n",
      "gzsl: unseen=0.5081 , seen=0.8122 , h=0.6251\n",
      "____________________________________________________________________________________________________\n",
      "episode: 40800 loss tensor(2.0523, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6411342683608868\n",
      "gzsl: unseen=0.5016 , seen=0.8050 , h=0.6181\n",
      "____________________________________________________________________________________________________\n",
      "episode: 41000 loss tensor(1.2623, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6458622801676844\n",
      "gzsl: unseen=0.5054 , seen=0.8110 , h=0.6227\n",
      "____________________________________________________________________________________________________\n",
      "episode: 41200 loss tensor(0.8423, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6510948968255665\n",
      "gzsl: unseen=0.5082 , seen=0.8109 , h=0.6248\n",
      "____________________________________________________________________________________________________\n",
      "episode: 41400 loss tensor(1.8908, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6577456289047693\n",
      "gzsl: unseen=0.5151 , seen=0.8106 , h=0.6299\n",
      "____________________________________________________________________________________________________\n",
      "episode: 41600 loss tensor(3.2970, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6504837854305483\n",
      "gzsl: unseen=0.5067 , seen=0.8103 , h=0.6235\n",
      "____________________________________________________________________________________________________\n",
      "episode: 41800 loss tensor(2.3366, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.648992115837046\n",
      "gzsl: unseen=0.5127 , seen=0.8064 , h=0.6268\n",
      "____________________________________________________________________________________________________\n",
      "episode: 42000 loss tensor(1.9118, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6655245829843617\n",
      "gzsl: unseen=0.5187 , seen=0.8140 , h=0.6336\n",
      "____________________________________________________________________________________________________\n",
      "episode: 42200 loss tensor(1.1876, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6590015800850567\n",
      "gzsl: unseen=0.5202 , seen=0.8077 , h=0.6328\n",
      "____________________________________________________________________________________________________\n",
      "episode: 42400 loss tensor(2.2069, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6541105364287179\n",
      "gzsl: unseen=0.5179 , seen=0.8040 , h=0.6300\n",
      "____________________________________________________________________________________________________\n",
      "episode: 42600 loss tensor(1.3750, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6444047996136046\n",
      "gzsl: unseen=0.4963 , seen=0.8101 , h=0.6155\n",
      "____________________________________________________________________________________________________\n",
      "episode: 42800 loss tensor(2.0675, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6483012819460826\n",
      "gzsl: unseen=0.5083 , seen=0.8110 , h=0.6249\n",
      "____________________________________________________________________________________________________\n",
      "episode: 43000 loss tensor(2.2374, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6593857657457167\n",
      "gzsl: unseen=0.5170 , seen=0.8094 , h=0.6310\n",
      "____________________________________________________________________________________________________\n",
      "episode: 43200 loss tensor(1.6794, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.647106762166798\n",
      "gzsl: unseen=0.5099 , seen=0.8137 , h=0.6269\n",
      "____________________________________________________________________________________________________\n",
      "episode: 43400 loss tensor(3.9049, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6504301093499805\n",
      "gzsl: unseen=0.5097 , seen=0.8137 , h=0.6267\n",
      "____________________________________________________________________________________________________\n",
      "episode: 43600 loss tensor(1.5275, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6517708788810838\n",
      "gzsl: unseen=0.5093 , seen=0.8107 , h=0.6256\n",
      "____________________________________________________________________________________________________\n",
      "episode: 43800 loss tensor(1.3431, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.644805588904632\n",
      "gzsl: unseen=0.5018 , seen=0.8114 , h=0.6201\n",
      "____________________________________________________________________________________________________\n",
      "episode: 44000 loss tensor(2.2036, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6494792903754016\n",
      "gzsl: unseen=0.5051 , seen=0.8075 , h=0.6214\n",
      "____________________________________________________________________________________________________\n",
      "episode: 44200 loss tensor(2.1859, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6508841073818125\n",
      "gzsl: unseen=0.5073 , seen=0.8094 , h=0.6237\n",
      "____________________________________________________________________________________________________\n",
      "episode: 44400 loss tensor(1.9523, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.654171053397447\n",
      "gzsl: unseen=0.5129 , seen=0.8115 , h=0.6285\n",
      "____________________________________________________________________________________________________\n",
      "episode: 44600 loss tensor(3.8739, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.654032115199673\n",
      "gzsl: unseen=0.5087 , seen=0.8138 , h=0.6260\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 44800 loss tensor(1.0911, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6565019482738761\n",
      "gzsl: unseen=0.5150 , seen=0.8095 , h=0.6295\n",
      "____________________________________________________________________________________________________\n",
      "episode: 45000 loss tensor(2.1030, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6546857604907221\n",
      "gzsl: unseen=0.5142 , seen=0.8089 , h=0.6287\n",
      "____________________________________________________________________________________________________\n",
      "episode: 45200 loss tensor(2.0022, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6552232568036682\n",
      "gzsl: unseen=0.5058 , seen=0.8141 , h=0.6239\n",
      "____________________________________________________________________________________________________\n",
      "episode: 45400 loss tensor(1.5169, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6524529364568351\n",
      "gzsl: unseen=0.5084 , seen=0.8120 , h=0.6253\n",
      "____________________________________________________________________________________________________\n",
      "episode: 45600 loss tensor(2.4354, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.65320457321646\n",
      "gzsl: unseen=0.5123 , seen=0.8152 , h=0.6292\n",
      "____________________________________________________________________________________________________\n",
      "episode: 45800 loss tensor(0.6915, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6555400840816222\n",
      "gzsl: unseen=0.5152 , seen=0.8118 , h=0.6304\n",
      "____________________________________________________________________________________________________\n",
      "episode: 46000 loss tensor(1.4184, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6515198215000203\n",
      "gzsl: unseen=0.5082 , seen=0.8121 , h=0.6252\n",
      "____________________________________________________________________________________________________\n",
      "episode: 46200 loss tensor(1.3470, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.653396729271053\n",
      "gzsl: unseen=0.5072 , seen=0.8106 , h=0.6240\n",
      "____________________________________________________________________________________________________\n",
      "episode: 46400 loss tensor(1.0790, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6695830856783618\n",
      "gzsl: unseen=0.5228 , seen=0.8109 , h=0.6358\n",
      "____________________________________________________________________________________________________\n",
      "episode: 46600 loss tensor(2.0105, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6588610981656101\n",
      "gzsl: unseen=0.5229 , seen=0.8137 , h=0.6366\n",
      "____________________________________________________________________________________________________\n",
      "episode: 46800 loss tensor(1.2999, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6504210177671705\n",
      "gzsl: unseen=0.5081 , seen=0.8093 , h=0.6242\n",
      "____________________________________________________________________________________________________\n",
      "episode: 47000 loss tensor(1.6102, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6514778604165665\n",
      "gzsl: unseen=0.5156 , seen=0.8106 , h=0.6303\n",
      "____________________________________________________________________________________________________\n",
      "episode: 47200 loss tensor(2.1789, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6520955580667568\n",
      "gzsl: unseen=0.5182 , seen=0.8071 , h=0.6311\n",
      "____________________________________________________________________________________________________\n",
      "episode: 47400 loss tensor(2.1910, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6554016017051932\n",
      "gzsl: unseen=0.5219 , seen=0.8135 , h=0.6358\n",
      "____________________________________________________________________________________________________\n",
      "episode: 47600 loss tensor(1.8058, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6572061367759992\n",
      "gzsl: unseen=0.5257 , seen=0.8103 , h=0.6377\n",
      "____________________________________________________________________________________________________\n",
      "episode: 47800 loss tensor(1.0902, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6507727612973471\n",
      "gzsl: unseen=0.5225 , seen=0.8076 , h=0.6345\n",
      "____________________________________________________________________________________________________\n",
      "episode: 48000 loss tensor(1.4949, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6532450621318115\n",
      "gzsl: unseen=0.5175 , seen=0.8080 , h=0.6309\n",
      "____________________________________________________________________________________________________\n",
      "episode: 48200 loss tensor(0.5911, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6507377923650225\n",
      "gzsl: unseen=0.5145 , seen=0.8059 , h=0.6280\n",
      "____________________________________________________________________________________________________\n",
      "episode: 48400 loss tensor(2.0083, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6516170912605045\n",
      "gzsl: unseen=0.5121 , seen=0.8107 , h=0.6277\n",
      "____________________________________________________________________________________________________\n",
      "episode: 48600 loss tensor(2.4956, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6471729037372473\n",
      "gzsl: unseen=0.5042 , seen=0.8115 , h=0.6220\n",
      "____________________________________________________________________________________________________\n",
      "episode: 48800 loss tensor(2.6427, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6457332284500166\n",
      "gzsl: unseen=0.5049 , seen=0.8108 , h=0.6223\n",
      "____________________________________________________________________________________________________\n",
      "episode: 49000 loss tensor(1.6562, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6475905735490255\n",
      "gzsl: unseen=0.5060 , seen=0.8099 , h=0.6229\n",
      "____________________________________________________________________________________________________\n",
      "episode: 49200 loss tensor(1.3639, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.643772162574429\n",
      "gzsl: unseen=0.5054 , seen=0.8109 , h=0.6227\n",
      "____________________________________________________________________________________________________\n",
      "episode: 49400 loss tensor(1.4272, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6485593407263366\n",
      "gzsl: unseen=0.5121 , seen=0.8070 , h=0.6266\n",
      "____________________________________________________________________________________________________\n",
      "episode: 49600 loss tensor(2.1650, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6480704019504382\n",
      "gzsl: unseen=0.5015 , seen=0.8109 , h=0.6197\n",
      "____________________________________________________________________________________________________\n",
      "episode: 49800 loss tensor(1.7667, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.647108424869711\n",
      "gzsl: unseen=0.5009 , seen=0.8087 , h=0.6186\n",
      "____________________________________________________________________________________________________\n",
      "episode: 50000 loss tensor(2.1263, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6458139165603538\n",
      "gzsl: unseen=0.5010 , seen=0.8134 , h=0.6201\n",
      "____________________________________________________________________________________________________\n",
      "episode: 50200 loss tensor(1.8202, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6504769145312497\n",
      "gzsl: unseen=0.5110 , seen=0.8074 , h=0.6259\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 50400 loss tensor(1.3429, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6506303597058318\n",
      "gzsl: unseen=0.5150 , seen=0.8086 , h=0.6292\n",
      "____________________________________________________________________________________________________\n",
      "episode: 50600 loss tensor(1.7284, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6420179571599111\n",
      "gzsl: unseen=0.5021 , seen=0.8120 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 50800 loss tensor(2.3403, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6467452240949634\n",
      "gzsl: unseen=0.5023 , seen=0.8109 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 51000 loss tensor(1.3741, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.648908467370266\n",
      "gzsl: unseen=0.5045 , seen=0.8122 , h=0.6224\n",
      "____________________________________________________________________________________________________\n",
      "episode: 51200 loss tensor(1.2943, device='cuda:0')\n",
      "loss_zero_number=  1\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6425273035671506\n",
      "gzsl: unseen=0.5010 , seen=0.8115 , h=0.6195\n",
      "____________________________________________________________________________________________________\n",
      "episode: 51400 loss tensor(1.6119, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6414675899712108\n",
      "gzsl: unseen=0.4946 , seen=0.8128 , h=0.6150\n",
      "____________________________________________________________________________________________________\n",
      "episode: 51600 loss tensor(1.3633, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6508085084095918\n",
      "gzsl: unseen=0.5049 , seen=0.8108 , h=0.6223\n",
      "____________________________________________________________________________________________________\n",
      "episode: 51800 loss tensor(2.8092, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6522426755406698\n",
      "gzsl: unseen=0.5071 , seen=0.8100 , h=0.6237\n",
      "____________________________________________________________________________________________________\n",
      "episode: 52000 loss tensor(1.2548, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6498169873478972\n",
      "gzsl: unseen=0.5039 , seen=0.8109 , h=0.6216\n",
      "____________________________________________________________________________________________________\n",
      "episode: 52200 loss tensor(0.9882, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.650002325741891\n",
      "gzsl: unseen=0.5067 , seen=0.8087 , h=0.6230\n",
      "____________________________________________________________________________________________________\n",
      "episode: 52400 loss tensor(1.2247, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.64794831273317\n",
      "gzsl: unseen=0.5107 , seen=0.8086 , h=0.6260\n",
      "____________________________________________________________________________________________________\n",
      "episode: 52600 loss tensor(1.2195, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.651652024774165\n",
      "gzsl: unseen=0.5082 , seen=0.8114 , h=0.6250\n",
      "____________________________________________________________________________________________________\n",
      "episode: 52800 loss tensor(2.7263, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6494339348276923\n",
      "gzsl: unseen=0.5017 , seen=0.8179 , h=0.6219\n",
      "____________________________________________________________________________________________________\n",
      "episode: 53000 loss tensor(1.0605, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6475030833690625\n",
      "gzsl: unseen=0.5037 , seen=0.8146 , h=0.6225\n",
      "____________________________________________________________________________________________________\n",
      "episode: 53200 loss tensor(1.0966, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6525528910027123\n",
      "gzsl: unseen=0.5056 , seen=0.8151 , h=0.6241\n",
      "____________________________________________________________________________________________________\n",
      "episode: 53400 loss tensor(1.3439, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6489208107630924\n",
      "gzsl: unseen=0.5068 , seen=0.8087 , h=0.6231\n",
      "____________________________________________________________________________________________________\n",
      "episode: 53600 loss tensor(4.4980, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.645711605034071\n",
      "gzsl: unseen=0.5001 , seen=0.8104 , h=0.6185\n",
      "____________________________________________________________________________________________________\n",
      "episode: 53800 loss tensor(1.5437, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6407737319873629\n",
      "gzsl: unseen=0.4916 , seen=0.8154 , h=0.6134\n",
      "____________________________________________________________________________________________________\n",
      "episode: 54000 loss tensor(1.5117, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6404012454912775\n",
      "gzsl: unseen=0.4938 , seen=0.8137 , h=0.6146\n",
      "____________________________________________________________________________________________________\n",
      "episode: 54200 loss tensor(1.7448, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6391970399825573\n",
      "gzsl: unseen=0.4929 , seen=0.8128 , h=0.6137\n",
      "____________________________________________________________________________________________________\n",
      "episode: 54400 loss tensor(2.3621, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6485864967898556\n",
      "gzsl: unseen=0.4975 , seen=0.8155 , h=0.6180\n",
      "____________________________________________________________________________________________________\n",
      "episode: 54600 loss tensor(2.7556, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6450372023718602\n",
      "gzsl: unseen=0.4950 , seen=0.8135 , h=0.6155\n",
      "____________________________________________________________________________________________________\n",
      "episode: 54800 loss tensor(0.9998, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6448623985330771\n",
      "gzsl: unseen=0.4965 , seen=0.8130 , h=0.6165\n",
      "____________________________________________________________________________________________________\n",
      "episode: 55000 loss tensor(1.3550, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6468699105274772\n",
      "gzsl: unseen=0.5096 , seen=0.8126 , h=0.6264\n",
      "____________________________________________________________________________________________________\n",
      "episode: 55200 loss tensor(1.9475, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6457505646555826\n",
      "gzsl: unseen=0.5029 , seen=0.8120 , h=0.6211\n",
      "____________________________________________________________________________________________________\n",
      "episode: 55400 loss tensor(1.3088, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6478697962265956\n",
      "gzsl: unseen=0.5039 , seen=0.8157 , h=0.6230\n",
      "____________________________________________________________________________________________________\n",
      "episode: 55600 loss tensor(1.6313, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6477483627722077\n",
      "gzsl: unseen=0.5035 , seen=0.8106 , h=0.6211\n",
      "____________________________________________________________________________________________________\n",
      "episode: 55800 loss tensor(2.4452, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6540701548976985\n",
      "gzsl: unseen=0.5128 , seen=0.8099 , h=0.6279\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 56000 loss tensor(0.9404, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6518231107648149\n",
      "gzsl: unseen=0.5096 , seen=0.8084 , h=0.6251\n",
      "____________________________________________________________________________________________________\n",
      "episode: 56200 loss tensor(1.7193, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6393909706935499\n",
      "gzsl: unseen=0.5027 , seen=0.8103 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 56400 loss tensor(1.6477, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6470725555330809\n",
      "gzsl: unseen=0.5070 , seen=0.8131 , h=0.6245\n",
      "____________________________________________________________________________________________________\n",
      "episode: 56600 loss tensor(1.6655, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.648307907607111\n",
      "gzsl: unseen=0.5038 , seen=0.8151 , h=0.6227\n",
      "____________________________________________________________________________________________________\n",
      "episode: 56800 loss tensor(1.5131, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6470273659107746\n",
      "gzsl: unseen=0.4996 , seen=0.8190 , h=0.6206\n",
      "____________________________________________________________________________________________________\n",
      "episode: 57000 loss tensor(1.7626, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6432728323977033\n",
      "gzsl: unseen=0.5028 , seen=0.8145 , h=0.6217\n",
      "____________________________________________________________________________________________________\n",
      "episode: 57200 loss tensor(2.7025, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6478608373210323\n",
      "gzsl: unseen=0.5021 , seen=0.8111 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 57400 loss tensor(1.4107, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6389288445003413\n",
      "gzsl: unseen=0.4848 , seen=0.8138 , h=0.6076\n",
      "____________________________________________________________________________________________________\n",
      "episode: 57600 loss tensor(1.0991, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6410718315620578\n",
      "gzsl: unseen=0.4917 , seen=0.8081 , h=0.6114\n",
      "____________________________________________________________________________________________________\n",
      "episode: 57800 loss tensor(1.2914, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6308946643403558\n",
      "gzsl: unseen=0.4768 , seen=0.8131 , h=0.6011\n",
      "____________________________________________________________________________________________________\n",
      "episode: 58000 loss tensor(1.4534, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6461909547329626\n",
      "gzsl: unseen=0.5026 , seen=0.8131 , h=0.6212\n",
      "____________________________________________________________________________________________________\n",
      "episode: 58200 loss tensor(2.0106, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409046324129593\n",
      "gzsl: unseen=0.4915 , seen=0.8151 , h=0.6132\n",
      "____________________________________________________________________________________________________\n",
      "episode: 58400 loss tensor(1.7510, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6428226753737618\n",
      "gzsl: unseen=0.4927 , seen=0.8149 , h=0.6141\n",
      "____________________________________________________________________________________________________\n",
      "episode: 58600 loss tensor(1.8143, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6450387689027748\n",
      "gzsl: unseen=0.5013 , seen=0.8129 , h=0.6202\n",
      "____________________________________________________________________________________________________\n",
      "episode: 58800 loss tensor(0.9860, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6439551859142433\n",
      "gzsl: unseen=0.4949 , seen=0.8158 , h=0.6161\n",
      "____________________________________________________________________________________________________\n",
      "episode: 59000 loss tensor(1.9493, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6458334757873547\n",
      "gzsl: unseen=0.5024 , seen=0.8143 , h=0.6214\n",
      "____________________________________________________________________________________________________\n",
      "episode: 59200 loss tensor(1.8214, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6419392958039984\n",
      "gzsl: unseen=0.5004 , seen=0.8110 , h=0.6189\n",
      "____________________________________________________________________________________________________\n",
      "episode: 59400 loss tensor(2.9277, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408105597007054\n",
      "gzsl: unseen=0.5033 , seen=0.8131 , h=0.6218\n",
      "____________________________________________________________________________________________________\n",
      "episode: 59600 loss tensor(1.9484, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6352860807306098\n",
      "gzsl: unseen=0.4949 , seen=0.8114 , h=0.6148\n",
      "____________________________________________________________________________________________________\n",
      "episode: 59800 loss tensor(0.9351, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6340875527202704\n",
      "gzsl: unseen=0.4887 , seen=0.8117 , h=0.6101\n",
      "____________________________________________________________________________________________________\n",
      "episode: 60000 loss tensor(2.0966, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.637302979300093\n",
      "gzsl: unseen=0.4940 , seen=0.8096 , h=0.6136\n",
      "____________________________________________________________________________________________________\n",
      "episode: 60200 loss tensor(2.2156, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6412830616186337\n",
      "gzsl: unseen=0.4966 , seen=0.8105 , h=0.6159\n",
      "____________________________________________________________________________________________________\n",
      "episode: 60400 loss tensor(2.0145, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6443667235692091\n",
      "gzsl: unseen=0.5090 , seen=0.8117 , h=0.6257\n",
      "____________________________________________________________________________________________________\n",
      "episode: 60600 loss tensor(0.5601, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6403093310176827\n",
      "gzsl: unseen=0.5002 , seen=0.8109 , h=0.6187\n",
      "____________________________________________________________________________________________________\n",
      "episode: 60800 loss tensor(2.4343, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6431541693156191\n",
      "gzsl: unseen=0.5038 , seen=0.8109 , h=0.6215\n",
      "____________________________________________________________________________________________________\n",
      "episode: 61000 loss tensor(1.6286, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6451183427652165\n",
      "gzsl: unseen=0.5096 , seen=0.8117 , h=0.6261\n",
      "____________________________________________________________________________________________________\n",
      "episode: 61200 loss tensor(1.6719, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6391767635766648\n",
      "gzsl: unseen=0.5103 , seen=0.8098 , h=0.6261\n",
      "____________________________________________________________________________________________________\n",
      "episode: 61400 loss tensor(1.6854, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6365129735937373\n",
      "gzsl: unseen=0.5031 , seen=0.8116 , h=0.6212\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 61600 loss tensor(2.0226, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6401993373035977\n",
      "gzsl: unseen=0.5019 , seen=0.8138 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 61800 loss tensor(3.1255, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6425020622016993\n",
      "gzsl: unseen=0.5041 , seen=0.8123 , h=0.6221\n",
      "____________________________________________________________________________________________________\n",
      "episode: 62000 loss tensor(2.0989, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409628271549578\n",
      "gzsl: unseen=0.5029 , seen=0.8105 , h=0.6207\n",
      "____________________________________________________________________________________________________\n",
      "episode: 62200 loss tensor(1.6751, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6399843964808902\n",
      "gzsl: unseen=0.5046 , seen=0.8109 , h=0.6221\n",
      "____________________________________________________________________________________________________\n",
      "episode: 62400 loss tensor(1.0256, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6395792056371742\n",
      "gzsl: unseen=0.5046 , seen=0.8108 , h=0.6221\n",
      "____________________________________________________________________________________________________\n",
      "episode: 62600 loss tensor(2.1482, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.641403796824959\n",
      "gzsl: unseen=0.5022 , seen=0.8113 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 62800 loss tensor(1.6114, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.640533886531953\n",
      "gzsl: unseen=0.5063 , seen=0.8120 , h=0.6237\n",
      "____________________________________________________________________________________________________\n",
      "episode: 63000 loss tensor(1.2920, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6428463030596309\n",
      "gzsl: unseen=0.5011 , seen=0.8125 , h=0.6199\n",
      "____________________________________________________________________________________________________\n",
      "episode: 63200 loss tensor(1.5130, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6417636633928527\n",
      "gzsl: unseen=0.5031 , seen=0.8124 , h=0.6214\n",
      "____________________________________________________________________________________________________\n",
      "episode: 63400 loss tensor(1.7492, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.64316362325507\n",
      "gzsl: unseen=0.5020 , seen=0.8126 , h=0.6206\n",
      "____________________________________________________________________________________________________\n",
      "episode: 63600 loss tensor(1.2348, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6397063218034713\n",
      "gzsl: unseen=0.5017 , seen=0.8143 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 63800 loss tensor(1.1176, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6406978166833466\n",
      "gzsl: unseen=0.5014 , seen=0.8131 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 64000 loss tensor(1.0006, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6436393669142207\n",
      "gzsl: unseen=0.5018 , seen=0.8145 , h=0.6210\n",
      "____________________________________________________________________________________________________\n",
      "episode: 64200 loss tensor(1.7766, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6386984107048279\n",
      "gzsl: unseen=0.4980 , seen=0.8110 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 64400 loss tensor(0.6901, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6390825374845759\n",
      "gzsl: unseen=0.4978 , seen=0.8126 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 64600 loss tensor(1.4069, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6372504058063688\n",
      "gzsl: unseen=0.4950 , seen=0.8142 , h=0.6157\n",
      "____________________________________________________________________________________________________\n",
      "episode: 64800 loss tensor(1.2332, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6419908472729875\n",
      "gzsl: unseen=0.5051 , seen=0.8127 , h=0.6230\n",
      "____________________________________________________________________________________________________\n",
      "episode: 65000 loss tensor(1.2464, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6421950736841551\n",
      "gzsl: unseen=0.5015 , seen=0.8131 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 65200 loss tensor(1.2556, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6450410668069967\n",
      "gzsl: unseen=0.5040 , seen=0.8126 , h=0.6221\n",
      "____________________________________________________________________________________________________\n",
      "episode: 65400 loss tensor(1.6876, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.642290800654352\n",
      "gzsl: unseen=0.5019 , seen=0.8127 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 65600 loss tensor(1.8636, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.642573080054248\n",
      "gzsl: unseen=0.5001 , seen=0.8126 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 65800 loss tensor(2.2169, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6433830783750303\n",
      "gzsl: unseen=0.5024 , seen=0.8114 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 66000 loss tensor(2.0810, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6415790060796365\n",
      "gzsl: unseen=0.5033 , seen=0.8116 , h=0.6214\n",
      "____________________________________________________________________________________________________\n",
      "episode: 66200 loss tensor(1.5254, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6403419755009166\n",
      "gzsl: unseen=0.5001 , seen=0.8106 , h=0.6185\n",
      "____________________________________________________________________________________________________\n",
      "episode: 66400 loss tensor(1.7331, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.640849803700408\n",
      "gzsl: unseen=0.5018 , seen=0.8141 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 66600 loss tensor(2.1228, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.641860756263587\n",
      "gzsl: unseen=0.5016 , seen=0.8126 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 66800 loss tensor(1.2921, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6443368280294637\n",
      "gzsl: unseen=0.5057 , seen=0.8139 , h=0.6238\n",
      "____________________________________________________________________________________________________\n",
      "episode: 67000 loss tensor(1.3715, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6493628256453101\n",
      "gzsl: unseen=0.5087 , seen=0.8134 , h=0.6259\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 67200 loss tensor(1.9795, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6479745242892392\n",
      "gzsl: unseen=0.5073 , seen=0.8143 , h=0.6251\n",
      "____________________________________________________________________________________________________\n",
      "episode: 67400 loss tensor(2.4261, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6480142044525865\n",
      "gzsl: unseen=0.5104 , seen=0.8152 , h=0.6278\n",
      "____________________________________________________________________________________________________\n",
      "episode: 67600 loss tensor(1.7508, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6437446482641679\n",
      "gzsl: unseen=0.5011 , seen=0.8145 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 67800 loss tensor(0.9529, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6432572084968928\n",
      "gzsl: unseen=0.5040 , seen=0.8117 , h=0.6219\n",
      "____________________________________________________________________________________________________\n",
      "episode: 68000 loss tensor(1.2240, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.645736847455259\n",
      "gzsl: unseen=0.5055 , seen=0.8120 , h=0.6231\n",
      "____________________________________________________________________________________________________\n",
      "episode: 68200 loss tensor(1.0878, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6460945790877007\n",
      "gzsl: unseen=0.5002 , seen=0.8148 , h=0.6199\n",
      "____________________________________________________________________________________________________\n",
      "episode: 68400 loss tensor(1.8779, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6439438533146078\n",
      "gzsl: unseen=0.5076 , seen=0.8123 , h=0.6248\n",
      "____________________________________________________________________________________________________\n",
      "episode: 68600 loss tensor(2.1102, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6416873043368383\n",
      "gzsl: unseen=0.5036 , seen=0.8121 , h=0.6217\n",
      "____________________________________________________________________________________________________\n",
      "episode: 68800 loss tensor(1.6075, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6441279512272785\n",
      "gzsl: unseen=0.5034 , seen=0.8136 , h=0.6220\n",
      "____________________________________________________________________________________________________\n",
      "episode: 69000 loss tensor(1.2722, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6442774908983002\n",
      "gzsl: unseen=0.5057 , seen=0.8124 , h=0.6234\n",
      "____________________________________________________________________________________________________\n",
      "episode: 69200 loss tensor(2.2338, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6458902765231948\n",
      "gzsl: unseen=0.5106 , seen=0.8118 , h=0.6269\n",
      "____________________________________________________________________________________________________\n",
      "episode: 69400 loss tensor(1.1405, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.640837405579186\n",
      "gzsl: unseen=0.5067 , seen=0.8105 , h=0.6235\n",
      "____________________________________________________________________________________________________\n",
      "episode: 69600 loss tensor(2.0256, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6407765842151784\n",
      "gzsl: unseen=0.5028 , seen=0.8121 , h=0.6211\n",
      "____________________________________________________________________________________________________\n",
      "episode: 69800 loss tensor(2.3716, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6423844925458067\n",
      "gzsl: unseen=0.5019 , seen=0.8140 , h=0.6209\n",
      "____________________________________________________________________________________________________\n",
      "episode: 70000 loss tensor(0.6884, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6436397487149901\n",
      "gzsl: unseen=0.5037 , seen=0.8137 , h=0.6222\n",
      "____________________________________________________________________________________________________\n",
      "episode: 70200 loss tensor(0.9262, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6436926624811937\n",
      "gzsl: unseen=0.5024 , seen=0.8133 , h=0.6211\n",
      "____________________________________________________________________________________________________\n",
      "episode: 70400 loss tensor(1.7786, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6417339026543198\n",
      "gzsl: unseen=0.4911 , seen=0.8169 , h=0.6134\n",
      "____________________________________________________________________________________________________\n",
      "episode: 70600 loss tensor(1.7499, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6440232284233549\n",
      "gzsl: unseen=0.5064 , seen=0.8150 , h=0.6246\n",
      "____________________________________________________________________________________________________\n",
      "episode: 70800 loss tensor(1.5815, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6434327750232358\n",
      "gzsl: unseen=0.4996 , seen=0.8141 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 71000 loss tensor(2.3219, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6425602355692416\n",
      "gzsl: unseen=0.4989 , seen=0.8126 , h=0.6182\n",
      "____________________________________________________________________________________________________\n",
      "episode: 71200 loss tensor(1.7556, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6463100676102023\n",
      "gzsl: unseen=0.5086 , seen=0.8131 , h=0.6258\n",
      "____________________________________________________________________________________________________\n",
      "episode: 71400 loss tensor(2.2725, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418905481545647\n",
      "gzsl: unseen=0.5069 , seen=0.8105 , h=0.6237\n",
      "____________________________________________________________________________________________________\n",
      "episode: 71600 loss tensor(2.6256, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6395849558789758\n",
      "gzsl: unseen=0.5029 , seen=0.8100 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 71800 loss tensor(2.1542, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6404448610967943\n",
      "gzsl: unseen=0.4986 , seen=0.8168 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 72000 loss tensor(1.9788, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6377460104414129\n",
      "gzsl: unseen=0.4952 , seen=0.8139 , h=0.6158\n",
      "____________________________________________________________________________________________________\n",
      "episode: 72200 loss tensor(2.9593, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6403135177785486\n",
      "gzsl: unseen=0.4990 , seen=0.8122 , h=0.6182\n",
      "____________________________________________________________________________________________________\n",
      "episode: 72400 loss tensor(1.3009, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6441361484246122\n",
      "gzsl: unseen=0.5006 , seen=0.8141 , h=0.6200\n",
      "____________________________________________________________________________________________________\n",
      "episode: 72600 loss tensor(1.8078, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6485414822731588\n",
      "gzsl: unseen=0.5079 , seen=0.8122 , h=0.6250\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 72800 loss tensor(1.4701, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6429605111894723\n",
      "gzsl: unseen=0.4986 , seen=0.8159 , h=0.6189\n",
      "____________________________________________________________________________________________________\n",
      "episode: 73000 loss tensor(1.4416, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6437954500512582\n",
      "gzsl: unseen=0.5024 , seen=0.8109 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 73200 loss tensor(2.6499, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.642660391228538\n",
      "gzsl: unseen=0.4999 , seen=0.8112 , h=0.6186\n",
      "____________________________________________________________________________________________________\n",
      "episode: 73400 loss tensor(1.9853, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6484947935588465\n",
      "gzsl: unseen=0.5069 , seen=0.8130 , h=0.6245\n",
      "____________________________________________________________________________________________________\n",
      "episode: 73600 loss tensor(1.1255, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6463641296512067\n",
      "gzsl: unseen=0.5036 , seen=0.8141 , h=0.6222\n",
      "____________________________________________________________________________________________________\n",
      "episode: 73800 loss tensor(0.9361, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6448207493559193\n",
      "gzsl: unseen=0.5048 , seen=0.8108 , h=0.6222\n",
      "____________________________________________________________________________________________________\n",
      "episode: 74000 loss tensor(1.8243, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6470296766570154\n",
      "gzsl: unseen=0.5095 , seen=0.8121 , h=0.6262\n",
      "____________________________________________________________________________________________________\n",
      "episode: 74200 loss tensor(2.8475, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6439637633087509\n",
      "gzsl: unseen=0.5086 , seen=0.8119 , h=0.6254\n",
      "____________________________________________________________________________________________________\n",
      "episode: 74400 loss tensor(1.1949, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6450835736179672\n",
      "gzsl: unseen=0.5063 , seen=0.8131 , h=0.6240\n",
      "____________________________________________________________________________________________________\n",
      "episode: 74600 loss tensor(1.6961, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6425081999208484\n",
      "gzsl: unseen=0.5011 , seen=0.8123 , h=0.6198\n",
      "____________________________________________________________________________________________________\n",
      "episode: 74800 loss tensor(2.3670, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6457543433380959\n",
      "gzsl: unseen=0.5043 , seen=0.8146 , h=0.6230\n",
      "____________________________________________________________________________________________________\n",
      "episode: 75000 loss tensor(1.6815, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6430864740465654\n",
      "gzsl: unseen=0.5025 , seen=0.8118 , h=0.6207\n",
      "____________________________________________________________________________________________________\n",
      "episode: 75200 loss tensor(1.1457, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418686097277894\n",
      "gzsl: unseen=0.4974 , seen=0.8122 , h=0.6170\n",
      "____________________________________________________________________________________________________\n",
      "episode: 75400 loss tensor(0.5687, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6452332882334508\n",
      "gzsl: unseen=0.5026 , seen=0.8127 , h=0.6211\n",
      "____________________________________________________________________________________________________\n",
      "episode: 75600 loss tensor(1.4178, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6456005879304509\n",
      "gzsl: unseen=0.5014 , seen=0.8127 , h=0.6202\n",
      "____________________________________________________________________________________________________\n",
      "episode: 75800 loss tensor(1.1737, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6445407718072756\n",
      "gzsl: unseen=0.5067 , seen=0.8120 , h=0.6240\n",
      "____________________________________________________________________________________________________\n",
      "episode: 76000 loss tensor(1.2331, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6429490861049524\n",
      "gzsl: unseen=0.4990 , seen=0.8129 , h=0.6184\n",
      "____________________________________________________________________________________________________\n",
      "episode: 76200 loss tensor(1.8244, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6435521789770595\n",
      "gzsl: unseen=0.4984 , seen=0.8151 , h=0.6186\n",
      "____________________________________________________________________________________________________\n",
      "episode: 76400 loss tensor(0.6258, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6433657947301648\n",
      "gzsl: unseen=0.4977 , seen=0.8139 , h=0.6177\n",
      "____________________________________________________________________________________________________\n",
      "episode: 76600 loss tensor(1.1071, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6449023971128438\n",
      "gzsl: unseen=0.5018 , seen=0.8118 , h=0.6202\n",
      "____________________________________________________________________________________________________\n",
      "episode: 76800 loss tensor(2.1558, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6407322959920176\n",
      "gzsl: unseen=0.5009 , seen=0.8112 , h=0.6193\n",
      "____________________________________________________________________________________________________\n",
      "episode: 77000 loss tensor(1.0738, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409817687603786\n",
      "gzsl: unseen=0.4991 , seen=0.8133 , h=0.6186\n",
      "____________________________________________________________________________________________________\n",
      "episode: 77200 loss tensor(0.7865, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6413155735501247\n",
      "gzsl: unseen=0.4967 , seen=0.8146 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 77400 loss tensor(1.5290, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6427728079602236\n",
      "gzsl: unseen=0.5027 , seen=0.8140 , h=0.6216\n",
      "____________________________________________________________________________________________________\n",
      "episode: 77600 loss tensor(2.4597, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6465947843581853\n",
      "gzsl: unseen=0.5003 , seen=0.8163 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 77800 loss tensor(2.5134, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.645421663581671\n",
      "gzsl: unseen=0.4952 , seen=0.8155 , h=0.6162\n",
      "____________________________________________________________________________________________________\n",
      "episode: 78000 loss tensor(1.2194, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6459359469879628\n",
      "gzsl: unseen=0.4941 , seen=0.8165 , h=0.6157\n",
      "____________________________________________________________________________________________________\n",
      "episode: 78200 loss tensor(1.9808, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6440298095127398\n",
      "gzsl: unseen=0.4964 , seen=0.8160 , h=0.6173\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 78400 loss tensor(0.7490, device='cuda:0')\n",
      "loss_zero_number=  1\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6434199613119\n",
      "gzsl: unseen=0.4935 , seen=0.8145 , h=0.6146\n",
      "____________________________________________________________________________________________________\n",
      "episode: 78600 loss tensor(0.5920, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6466255659155669\n",
      "gzsl: unseen=0.4934 , seen=0.8166 , h=0.6151\n",
      "____________________________________________________________________________________________________\n",
      "episode: 78800 loss tensor(2.4805, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6432101855722506\n",
      "gzsl: unseen=0.4912 , seen=0.8171 , h=0.6135\n",
      "____________________________________________________________________________________________________\n",
      "episode: 79000 loss tensor(1.3050, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6468929767324119\n",
      "gzsl: unseen=0.4968 , seen=0.8152 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 79200 loss tensor(1.8688, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6493461278203878\n",
      "gzsl: unseen=0.4960 , seen=0.8158 , h=0.6169\n",
      "____________________________________________________________________________________________________\n",
      "episode: 79400 loss tensor(1.4323, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6431050248545434\n",
      "gzsl: unseen=0.4898 , seen=0.8147 , h=0.6118\n",
      "____________________________________________________________________________________________________\n",
      "episode: 79600 loss tensor(1.2051, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6437790362220411\n",
      "gzsl: unseen=0.4959 , seen=0.8140 , h=0.6163\n",
      "____________________________________________________________________________________________________\n",
      "episode: 79800 loss tensor(1.0587, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6446956329946543\n",
      "gzsl: unseen=0.4913 , seen=0.8156 , h=0.6132\n",
      "____________________________________________________________________________________________________\n",
      "episode: 80000 loss tensor(1.4707, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6442263101489807\n",
      "gzsl: unseen=0.4918 , seen=0.8160 , h=0.6137\n",
      "____________________________________________________________________________________________________\n",
      "episode: 80200 loss tensor(2.0409, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6443575637845473\n",
      "gzsl: unseen=0.4964 , seen=0.8153 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 80400 loss tensor(2.1031, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6438263393203887\n",
      "gzsl: unseen=0.4968 , seen=0.8155 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 80600 loss tensor(1.6758, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6439375160603176\n",
      "gzsl: unseen=0.4980 , seen=0.8166 , h=0.6187\n",
      "____________________________________________________________________________________________________\n",
      "episode: 80800 loss tensor(1.9759, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6454788175875511\n",
      "gzsl: unseen=0.5031 , seen=0.8136 , h=0.6218\n",
      "____________________________________________________________________________________________________\n",
      "episode: 81000 loss tensor(2.2675, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6463601301210907\n",
      "gzsl: unseen=0.4992 , seen=0.8122 , h=0.6184\n",
      "____________________________________________________________________________________________________\n",
      "episode: 81200 loss tensor(2.4002, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.641617085057869\n",
      "gzsl: unseen=0.4940 , seen=0.8136 , h=0.6147\n",
      "____________________________________________________________________________________________________\n",
      "episode: 81400 loss tensor(0.9821, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6437955664400911\n",
      "gzsl: unseen=0.5002 , seen=0.8129 , h=0.6194\n",
      "____________________________________________________________________________________________________\n",
      "episode: 81600 loss tensor(1.5268, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6442140272060393\n",
      "gzsl: unseen=0.5000 , seen=0.8133 , h=0.6193\n",
      "____________________________________________________________________________________________________\n",
      "episode: 81800 loss tensor(2.6311, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6420771629417551\n",
      "gzsl: unseen=0.4951 , seen=0.8147 , h=0.6159\n",
      "____________________________________________________________________________________________________\n",
      "episode: 82000 loss tensor(1.2254, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.643455726894213\n",
      "gzsl: unseen=0.5015 , seen=0.8133 , h=0.6204\n",
      "____________________________________________________________________________________________________\n",
      "episode: 82200 loss tensor(2.2355, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6477345489306\n",
      "gzsl: unseen=0.5047 , seen=0.8138 , h=0.6230\n",
      "____________________________________________________________________________________________________\n",
      "episode: 82400 loss tensor(0.7716, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6473185506270915\n",
      "gzsl: unseen=0.5032 , seen=0.8143 , h=0.6220\n",
      "____________________________________________________________________________________________________\n",
      "episode: 82600 loss tensor(2.6183, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6428798229773592\n",
      "gzsl: unseen=0.5008 , seen=0.8126 , h=0.6197\n",
      "____________________________________________________________________________________________________\n",
      "episode: 82800 loss tensor(1.9699, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6432106848768081\n",
      "gzsl: unseen=0.5069 , seen=0.8133 , h=0.6246\n",
      "____________________________________________________________________________________________________\n",
      "episode: 83000 loss tensor(1.8276, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6406818525332518\n",
      "gzsl: unseen=0.5017 , seen=0.8124 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 83200 loss tensor(1.3080, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6412211303385467\n",
      "gzsl: unseen=0.5008 , seen=0.8132 , h=0.6199\n",
      "____________________________________________________________________________________________________\n",
      "episode: 83400 loss tensor(0.9362, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6426089236059924\n",
      "gzsl: unseen=0.4992 , seen=0.8138 , h=0.6188\n",
      "____________________________________________________________________________________________________\n",
      "episode: 83600 loss tensor(1.5288, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6451159353631398\n",
      "gzsl: unseen=0.5093 , seen=0.8126 , h=0.6261\n",
      "____________________________________________________________________________________________________\n",
      "episode: 83800 loss tensor(1.1339, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408282396502505\n",
      "gzsl: unseen=0.5028 , seen=0.8126 , h=0.6212\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 84000 loss tensor(1.9829, device='cuda:0')\n",
      "loss_zero_number=  2\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408356444408401\n",
      "gzsl: unseen=0.5049 , seen=0.8110 , h=0.6224\n",
      "____________________________________________________________________________________________________\n",
      "episode: 84200 loss tensor(1.2131, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6432512827276049\n",
      "gzsl: unseen=0.5044 , seen=0.8130 , h=0.6226\n",
      "____________________________________________________________________________________________________\n",
      "episode: 84400 loss tensor(1.0627, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6439287136516891\n",
      "gzsl: unseen=0.5059 , seen=0.8119 , h=0.6234\n",
      "____________________________________________________________________________________________________\n",
      "episode: 84600 loss tensor(2.1800, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6441191532269774\n",
      "gzsl: unseen=0.5021 , seen=0.8120 , h=0.6205\n",
      "____________________________________________________________________________________________________\n",
      "episode: 84800 loss tensor(2.1057, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6423505856339713\n",
      "gzsl: unseen=0.4995 , seen=0.8142 , h=0.6191\n",
      "____________________________________________________________________________________________________\n",
      "episode: 85000 loss tensor(1.1770, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6431423121213458\n",
      "gzsl: unseen=0.5043 , seen=0.8133 , h=0.6225\n",
      "____________________________________________________________________________________________________\n",
      "episode: 85200 loss tensor(2.4609, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6398552286840555\n",
      "gzsl: unseen=0.4986 , seen=0.8144 , h=0.6185\n",
      "____________________________________________________________________________________________________\n",
      "episode: 85400 loss tensor(0.9524, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6393090540307557\n",
      "gzsl: unseen=0.4977 , seen=0.8147 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 85600 loss tensor(1.0384, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6379229572153566\n",
      "gzsl: unseen=0.4973 , seen=0.8128 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 85800 loss tensor(1.5803, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6428625810805705\n",
      "gzsl: unseen=0.5006 , seen=0.8153 , h=0.6203\n",
      "____________________________________________________________________________________________________\n",
      "episode: 86000 loss tensor(1.0306, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6415000569465861\n",
      "gzsl: unseen=0.4986 , seen=0.8135 , h=0.6183\n",
      "____________________________________________________________________________________________________\n",
      "episode: 86200 loss tensor(1.1716, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6435514267560871\n",
      "gzsl: unseen=0.5025 , seen=0.8125 , h=0.6210\n",
      "____________________________________________________________________________________________________\n",
      "episode: 86400 loss tensor(1.8338, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408312543227471\n",
      "gzsl: unseen=0.4972 , seen=0.8121 , h=0.6168\n",
      "____________________________________________________________________________________________________\n",
      "episode: 86600 loss tensor(1.7201, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6426573065009318\n",
      "gzsl: unseen=0.5009 , seen=0.8133 , h=0.6199\n",
      "____________________________________________________________________________________________________\n",
      "episode: 86800 loss tensor(3.2726, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408369667032816\n",
      "gzsl: unseen=0.4995 , seen=0.8119 , h=0.6185\n",
      "____________________________________________________________________________________________________\n",
      "episode: 87000 loss tensor(1.3026, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6440192985948553\n",
      "gzsl: unseen=0.5005 , seen=0.8133 , h=0.6197\n",
      "____________________________________________________________________________________________________\n",
      "episode: 87200 loss tensor(0.7882, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6414331536578997\n",
      "gzsl: unseen=0.5001 , seen=0.8127 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 87400 loss tensor(1.9299, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6383039053712376\n",
      "gzsl: unseen=0.4960 , seen=0.8150 , h=0.6167\n",
      "____________________________________________________________________________________________________\n",
      "episode: 87600 loss tensor(1.6091, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6413302273562282\n",
      "gzsl: unseen=0.5006 , seen=0.8121 , h=0.6194\n",
      "____________________________________________________________________________________________________\n",
      "episode: 87800 loss tensor(2.3113, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6420600564324448\n",
      "gzsl: unseen=0.4978 , seen=0.8125 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 88000 loss tensor(1.6066, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418648457621892\n",
      "gzsl: unseen=0.4958 , seen=0.8136 , h=0.6161\n",
      "____________________________________________________________________________________________________\n",
      "episode: 88200 loss tensor(0.8621, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6402622648037911\n",
      "gzsl: unseen=0.4949 , seen=0.8134 , h=0.6154\n",
      "____________________________________________________________________________________________________\n",
      "episode: 88400 loss tensor(0.9259, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.641376478010104\n",
      "gzsl: unseen=0.4971 , seen=0.8135 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 88600 loss tensor(1.7416, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6425318646164881\n",
      "gzsl: unseen=0.4952 , seen=0.8154 , h=0.6162\n",
      "____________________________________________________________________________________________________\n",
      "episode: 88800 loss tensor(0.9816, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6404692082444094\n",
      "gzsl: unseen=0.4946 , seen=0.8151 , h=0.6156\n",
      "____________________________________________________________________________________________________\n",
      "episode: 89000 loss tensor(1.4611, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6410210836090571\n",
      "gzsl: unseen=0.4977 , seen=0.8155 , h=0.6182\n",
      "____________________________________________________________________________________________________\n",
      "episode: 89200 loss tensor(1.0628, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6448878139903585\n",
      "gzsl: unseen=0.4982 , seen=0.8133 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 89400 loss tensor(1.8186, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.644708159309707\n",
      "gzsl: unseen=0.5001 , seen=0.8129 , h=0.6192\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 89600 loss tensor(1.5944, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.642939545579683\n",
      "gzsl: unseen=0.4962 , seen=0.8148 , h=0.6168\n",
      "____________________________________________________________________________________________________\n",
      "episode: 89800 loss tensor(1.4590, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6403350567899048\n",
      "gzsl: unseen=0.4952 , seen=0.8157 , h=0.6163\n",
      "____________________________________________________________________________________________________\n",
      "episode: 90000 loss tensor(1.8622, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6405608534629286\n",
      "gzsl: unseen=0.4949 , seen=0.8151 , h=0.6159\n",
      "____________________________________________________________________________________________________\n",
      "episode: 90200 loss tensor(1.9694, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408753144660948\n",
      "gzsl: unseen=0.4975 , seen=0.8133 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 90400 loss tensor(2.3057, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6404660047127625\n",
      "gzsl: unseen=0.4982 , seen=0.8130 , h=0.6178\n",
      "____________________________________________________________________________________________________\n",
      "episode: 90600 loss tensor(1.4814, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6397937750045842\n",
      "gzsl: unseen=0.4975 , seen=0.8134 , h=0.6174\n",
      "____________________________________________________________________________________________________\n",
      "episode: 90800 loss tensor(0.9220, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418284193382194\n",
      "gzsl: unseen=0.4977 , seen=0.8144 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 91000 loss tensor(1.8337, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6417557029077583\n",
      "gzsl: unseen=0.4968 , seen=0.8144 , h=0.6171\n",
      "____________________________________________________________________________________________________\n",
      "episode: 91200 loss tensor(2.1338, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6422003086914718\n",
      "gzsl: unseen=0.4983 , seen=0.8140 , h=0.6182\n",
      "____________________________________________________________________________________________________\n",
      "episode: 91400 loss tensor(1.2609, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6440744306775612\n",
      "gzsl: unseen=0.4986 , seen=0.8123 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 91600 loss tensor(1.3473, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6368940699362404\n",
      "gzsl: unseen=0.4910 , seen=0.8142 , h=0.6126\n",
      "____________________________________________________________________________________________________\n",
      "episode: 91800 loss tensor(1.2836, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6362958481490578\n",
      "gzsl: unseen=0.4940 , seen=0.8155 , h=0.6153\n",
      "____________________________________________________________________________________________________\n",
      "episode: 92000 loss tensor(1.3762, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6387221017607267\n",
      "gzsl: unseen=0.4941 , seen=0.8136 , h=0.6148\n",
      "____________________________________________________________________________________________________\n",
      "episode: 92200 loss tensor(1.0172, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6388895227320512\n",
      "gzsl: unseen=0.4964 , seen=0.8130 , h=0.6164\n",
      "____________________________________________________________________________________________________\n",
      "episode: 92400 loss tensor(0.9854, device='cuda:0')\n",
      "loss_zero_number=  1\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6377006095792137\n",
      "gzsl: unseen=0.4950 , seen=0.8141 , h=0.6157\n",
      "____________________________________________________________________________________________________\n",
      "episode: 92600 loss tensor(2.2631, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409586823971487\n",
      "gzsl: unseen=0.4941 , seen=0.8155 , h=0.6154\n",
      "____________________________________________________________________________________________________\n",
      "episode: 92800 loss tensor(2.2226, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409337659807282\n",
      "gzsl: unseen=0.4968 , seen=0.8131 , h=0.6168\n",
      "____________________________________________________________________________________________________\n",
      "episode: 93000 loss tensor(2.4393, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6402035244460751\n",
      "gzsl: unseen=0.4967 , seen=0.8148 , h=0.6172\n",
      "____________________________________________________________________________________________________\n",
      "episode: 93200 loss tensor(0.8962, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6400320526893062\n",
      "gzsl: unseen=0.4957 , seen=0.8147 , h=0.6164\n",
      "____________________________________________________________________________________________________\n",
      "episode: 93400 loss tensor(1.9787, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6421402425757472\n",
      "gzsl: unseen=0.4990 , seen=0.8135 , h=0.6186\n",
      "____________________________________________________________________________________________________\n",
      "episode: 93600 loss tensor(2.3861, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6412455570687516\n",
      "gzsl: unseen=0.4951 , seen=0.8152 , h=0.6161\n",
      "____________________________________________________________________________________________________\n",
      "episode: 93800 loss tensor(0.9236, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6374242526208579\n",
      "gzsl: unseen=0.4954 , seen=0.8147 , h=0.6162\n",
      "____________________________________________________________________________________________________\n",
      "episode: 94000 loss tensor(1.1343, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6369303070739517\n",
      "gzsl: unseen=0.4931 , seen=0.8154 , h=0.6145\n",
      "____________________________________________________________________________________________________\n",
      "episode: 94200 loss tensor(1.3269, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6406999346951497\n",
      "gzsl: unseen=0.4986 , seen=0.8152 , h=0.6187\n",
      "____________________________________________________________________________________________________\n",
      "episode: 94400 loss tensor(1.2714, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6383238214067429\n",
      "gzsl: unseen=0.4905 , seen=0.8166 , h=0.6129\n",
      "____________________________________________________________________________________________________\n",
      "episode: 94600 loss tensor(1.8515, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6384428195195294\n",
      "gzsl: unseen=0.4922 , seen=0.8158 , h=0.6140\n",
      "____________________________________________________________________________________________________\n",
      "episode: 94800 loss tensor(1.6590, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6383552003323272\n",
      "gzsl: unseen=0.4927 , seen=0.8163 , h=0.6145\n",
      "____________________________________________________________________________________________________\n",
      "episode: 95000 loss tensor(1.2217, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6411002384709988\n",
      "gzsl: unseen=0.4974 , seen=0.8146 , h=0.6176\n",
      "____________________________________________________________________________________________________\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "episode: 95200 loss tensor(0.7898, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6427067179227672\n",
      "gzsl: unseen=0.4992 , seen=0.8145 , h=0.6190\n",
      "____________________________________________________________________________________________________\n",
      "episode: 95400 loss tensor(1.8375, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6406209964268843\n",
      "gzsl: unseen=0.4979 , seen=0.8141 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 95600 loss tensor(2.1343, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6445364056258048\n",
      "gzsl: unseen=0.4998 , seen=0.8136 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 95800 loss tensor(1.5809, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.643279153110482\n",
      "gzsl: unseen=0.4997 , seen=0.8123 , h=0.6188\n",
      "____________________________________________________________________________________________________\n",
      "episode: 96000 loss tensor(1.0302, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6413895237195495\n",
      "gzsl: unseen=0.4970 , seen=0.8126 , h=0.6168\n",
      "____________________________________________________________________________________________________\n",
      "episode: 96200 loss tensor(2.0515, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418252469927317\n",
      "gzsl: unseen=0.4995 , seen=0.8129 , h=0.6187\n",
      "____________________________________________________________________________________________________\n",
      "episode: 96400 loss tensor(1.9674, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408646944661048\n",
      "gzsl: unseen=0.4988 , seen=0.8122 , h=0.6181\n",
      "____________________________________________________________________________________________________\n",
      "episode: 96600 loss tensor(2.3772, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6403066038808373\n",
      "gzsl: unseen=0.4992 , seen=0.8122 , h=0.6183\n",
      "____________________________________________________________________________________________________\n",
      "episode: 96800 loss tensor(1.4360, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6386146263748226\n",
      "gzsl: unseen=0.4981 , seen=0.8135 , h=0.6179\n",
      "____________________________________________________________________________________________________\n",
      "episode: 97000 loss tensor(1.2359, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6401212696789318\n",
      "gzsl: unseen=0.5006 , seen=0.8127 , h=0.6196\n",
      "____________________________________________________________________________________________________\n",
      "episode: 97200 loss tensor(2.8445, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6431468038779403\n",
      "gzsl: unseen=0.5012 , seen=0.8122 , h=0.6199\n",
      "____________________________________________________________________________________________________\n",
      "episode: 97400 loss tensor(1.4913, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.641932192225538\n",
      "gzsl: unseen=0.4995 , seen=0.8126 , h=0.6187\n",
      "____________________________________________________________________________________________________\n",
      "episode: 97600 loss tensor(0.7261, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418201155326176\n",
      "gzsl: unseen=0.5008 , seen=0.8124 , h=0.6196\n",
      "____________________________________________________________________________________________________\n",
      "episode: 97800 loss tensor(1.2855, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6410031247775303\n",
      "gzsl: unseen=0.4974 , seen=0.8129 , h=0.6172\n",
      "____________________________________________________________________________________________________\n",
      "episode: 98000 loss tensor(0.8551, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.640188355055384\n",
      "gzsl: unseen=0.4964 , seen=0.8139 , h=0.6167\n",
      "____________________________________________________________________________________________________\n",
      "episode: 98200 loss tensor(2.2066, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6404891888570913\n",
      "gzsl: unseen=0.5007 , seen=0.8145 , h=0.6202\n",
      "____________________________________________________________________________________________________\n",
      "episode: 98400 loss tensor(1.5587, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6393869690986622\n",
      "gzsl: unseen=0.4971 , seen=0.8128 , h=0.6169\n",
      "____________________________________________________________________________________________________\n",
      "episode: 98600 loss tensor(1.6567, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6389104429106646\n",
      "gzsl: unseen=0.4960 , seen=0.8142 , h=0.6164\n",
      "____________________________________________________________________________________________________\n",
      "episode: 98800 loss tensor(2.1270, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6401741683896319\n",
      "gzsl: unseen=0.4975 , seen=0.8140 , h=0.6176\n",
      "____________________________________________________________________________________________________\n",
      "episode: 99000 loss tensor(1.7533, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6418129600395657\n",
      "gzsl: unseen=0.4990 , seen=0.8126 , h=0.6183\n",
      "____________________________________________________________________________________________________\n",
      "episode: 99200 loss tensor(1.7389, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6408635308835317\n",
      "gzsl: unseen=0.5001 , seen=0.8130 , h=0.6192\n",
      "____________________________________________________________________________________________________\n",
      "episode: 99400 loss tensor(1.6510, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.640634698566332\n",
      "gzsl: unseen=0.5005 , seen=0.8138 , h=0.6198\n",
      "____________________________________________________________________________________________________\n",
      "episode: 99600 loss tensor(1.6430, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6379186763326227\n",
      "gzsl: unseen=0.4965 , seen=0.8131 , h=0.6165\n",
      "____________________________________________________________________________________________________\n",
      "episode: 99800 loss tensor(1.0753, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6379657388861777\n",
      "gzsl: unseen=0.4994 , seen=0.8131 , h=0.6188\n",
      "____________________________________________________________________________________________________\n",
      "episode: 100000 loss tensor(1.8006, device='cuda:0')\n",
      "loss_zero_number=  0\n",
      "Testing...\n",
      "class num: 10\n",
      "class num: 50\n",
      "class num: 50\n",
      "zsl: 0.6409720309261929\n",
      "gzsl: unseen=0.4986 , seen=0.8154 , h=0.6188\n",
      "____________________________________________________________________________________________________\n"
     ]
    }
   ],
   "source": [
    "print(\"training...\")\n",
    "last_accuracy = 0.0\n",
    "loss_zero_num =0\n",
    "#writer = SummaryWriter()\n",
    "#vis = visdom.Visdom()\n",
    "for episode in range(EPISODE):\n",
    "\n",
    "    attribute_network_scheduler.step(episode)\n",
    "    metric_network_scheduler.step(episode)\n",
    "\n",
    "    train_loader = DataLoader(train_data, batch_size=BATCH_SIZE, shuffle=True)\n",
    "\n",
    "    batch_labels, batch_features = train_loader.__iter__().next()\n",
    "    batch_id = np.unique(batch_labels)\n",
    "\n",
    "    batch_attributes = torch.Tensor([all_attributes[i] for i in batch_id]).squeeze(1)\n",
    "    batch_features_ext = torch.from_numpy(batch_features.numpy().repeat(batch_id.size, 0))\n",
    "    batch_attributes_ext = batch_attributes.repeat(BATCH_SIZE, 1)\n",
    "\n",
    "    batch_features_ext = Variable(batch_features_ext).cuda(GPU).float()  # 32*2048\n",
    "    batch_attributes_ext = Variable(batch_attributes_ext).cuda(GPU)\n",
    "\n",
    "\n",
    "    re_batch_labels = []\n",
    "    for label in batch_labels.numpy():\n",
    "        index = np.argwhere(batch_id == label)\n",
    "        re_batch_labels.append(index[0][0])\n",
    "    re_batch_labels = torch.cuda.LongTensor(re_batch_labels)\n",
    "    re_batch_labels = Variable(re_batch_labels).cuda(GPU)\n",
    "    \n",
    "\n",
    "    criterion = HardTripletLoss(margin = Margin).cuda(GPU)\n",
    "    triplet_loss= criterion(metric_network(attribute_network(batch_attributes_ext)), \n",
    "                            metric_network(batch_features_ext), re_batch_labels)\n",
    "    if triplet_loss == 0:\n",
    "        loss_zero_num = loss_zero_num + 1\n",
    "    \n",
    "    \n",
    "    attribute_network.zero_grad()\n",
    "    metric_network.zero_grad()\n",
    "    \n",
    "    triplet_loss.backward()\n",
    "    \n",
    "    attribute_network_optim.step()\n",
    "    metric_network_optim.step()\n",
    "\n",
    "    \n",
    "    if (episode+1)%200 == 0 or episode==0:\n",
    "        print(\"episode:\", episode+1, \"loss\", triplet_loss)\n",
    "        print('loss_zero_number= ',loss_zero_num)\n",
    "        loss_zero_num = 0\n",
    "        #writer.add_scalar('data/loss', triplet_loss, episode)\n",
    "    \n",
    "    if (episode+1)%200 == 0 or episode==0:\n",
    "        print(\"Testing...\")\n",
    "        #attribute_network.eval()\n",
    "        zsl_accuracy = compute_accuracy_per_class(test_features, test_label, test_id, test_attributes)\n",
    "        gzsl_unseen_accuracy = compute_accuracy_per_class(test_features, test_label, np.arange(50), attributes)\n",
    "        gzsl_seen_accuracy = compute_accuracy_per_class(test_seen_features, test_seen_label, np.arange(50), attributes)\n",
    "        H = 2 * gzsl_seen_accuracy * gzsl_unseen_accuracy / (gzsl_unseen_accuracy + gzsl_seen_accuracy)\n",
    "        #H2 = 2 * gzsl_seen_accuracy2 * gzsl_unseen_accuracy2 / (gzsl_unseen_accuracy2 + gzsl_seen_accuracy2)\n",
    "        print('zsl:', zsl_accuracy)\n",
    "        #print('zsl:', zsl_accuracy2)\n",
    "        print('gzsl: unseen=%.4f , seen=%.4f , h=%.4f' % (gzsl_unseen_accuracy , gzsl_seen_accuracy, H))\n",
    "        #print('gzsl: unseen=%.4f , seen=%.4f , h=%.4f' % (gzsl_unseen_accuracy2 , gzsl_seen_accuracy2, H2))\n",
    "        print('_'*100)\n",
    "        #writer.add_scalar('data/zsl_accuracy', zsl_accuracy, episode)\n",
    "        #writer.add_scalar('data/gzsl_unseen_accuracy', gzsl_unseen_accuracy, episode)\n",
    "        #writer.add_scalar('data/gzsl_seen_accuracy', gzsl_seen_accuracy, episode)\n",
    "        #writer.add_scalar('data/H', H, episode)\n",
    "#features = images.view(, 784)\n",
    "#print(vis_label.size())\n",
    "#writer.add_embedding(vis_images, metadata = vis_label.tolist())\n",
    "#writer.add_embedding(vis_att, metadata = vis_label_att)\n",
    "#writer.export_scalars_to_json(\"./test.json\")\n",
    "#writer.close()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "hide_input": false,
  "kernelspec": {
   "display_name": "pytorch",
   "language": "python",
   "name": "pytorch"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.5.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
